Note that there are some explanatory texts on larger screens.

plurals
  1. POWhy don't my south migrations work?
    primarykey
    data
    text
    <p>First, I create my database.</p> <pre><code>create database mydb; </code></pre> <p>I add "south" to installed Apps. Then, I go to this tutorial: <a href="http://south.aeracode.org/docs/tutorial/part1.html" rel="noreferrer">http://south.aeracode.org/docs/tutorial/part1.html</a></p> <p>The tutorial tells me to do this:</p> <pre><code>$ py manage.py schemamigration wall --initial &gt;&gt;&gt; Created 0001_initial.py. You can now apply this migration with: ./manage.py migrate wall </code></pre> <p>Great, now I migrate.</p> <pre><code>$ py manage.py migrate wall </code></pre> <p>But it gives me this error...</p> <pre><code>django.db.utils.DatabaseError: (1146, "Table 'fable.south_migrationhistory' doesn't exist") </code></pre> <p>So I use Google (which never works. hence my 870 questions asked on Stackoverflow), and I get this page: <a href="http://groups.google.com/group/south-users/browse_thread/thread/d4c83f821dd2ca1c" rel="noreferrer">http://groups.google.com/group/south-users/browse_thread/thread/d4c83f821dd2ca1c</a></p> <p>Alright, so I follow that instructions</p> <pre><code>&gt;&gt; Drop database mydb; &gt;&gt; Create database mydb; $ rm -rf ./wall/migrations $ py manage.py syncdb </code></pre> <p>But when I run syncdb, Django creates a bunch of tables. Yes, it creates the south_migrationhistory table, but <strong>it also creates my app's tables.</strong></p> <pre><code>Synced: &gt; django.contrib.admin &gt; django.contrib.auth &gt; django.contrib.contenttypes &gt; django.contrib.sessions &gt; django.contrib.sites &gt; django.contrib.messages &gt; south &gt; fable.notification &gt; pagination &gt; timezones &gt; fable.wall &gt; mediasync &gt; staticfiles &gt; debug_toolbar Not synced (use migrations): - (use ./manage.py migrate to migrate these) </code></pre> <p>Cool....now it tells me to migrate these. So, I do this:</p> <pre><code>$ py manage.py migrate wall The app 'wall' does not appear to use migrations. </code></pre> <p>Alright, so fine. I'll add wall to initial migrations.</p> <pre><code>$ py manage.py schemamigration wall --initial </code></pre> <p>Then I migrate:</p> <pre><code>$ py manage.py migrate wall </code></pre> <p>You know what? It gives me this BS:</p> <pre><code>_mysql_exceptions.OperationalError: (1050, "Table 'wall_content' already exists") </code></pre> <p>Sorry, this is really pissing me off. Can someone help ? thanks.</p> <p>How do I get South to work and sync correctly with everything? The only thing I can think of is remove my app from INSTALLED_APPS, then run syncdb, then add it back on.</p> <p><strong>That is SO SILLY.</strong></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload