On Sun, May 8, 2011 at 4:25 PM, Adam Seering <aseer...@gmail.com> wrote: > I have some Python code that generates initial data for some of my tables; I > currently call that code from a post_syncdb hook. In Django 1.3, it looks like > Django now calls TRUNCATE (or an equivalent non-PostgreSQL-ism) on all tables > after running syncdb and all of its post- hooks.
That... doesn't sound right. Here's all the SQL syncdb executes (for a simple app with one table); notice the distinct lack of any TRUNCATE statement. Are you perhaps talking about doing this during testing? If so, you're looking for unittest's setUp method: http://docs.python.org/library/unittest.html#unittest.TestCase.setUp. Jacob -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.