title: django.db.utils.OperationalError: my_table has no column id error?
body: <p>I'm testing my models.py file of my Django app: "myapp" in my Python interepreter, but keep running into this error:   </p>
  
  <pre><code>django.db.utils.OperationalError: table myapp_table1 has no column named attribute1_id
  </code></pre>
  
  <p>I have 2 tables in my models.py, table1 and table 2. </p>
  
  <pre><code> class table1 (models.Model):
     name = models.CharField(max_length=25)
     def __str__(self):             
       return self.name
   class table2 (models.Model):
     name = models.CharField(max_length =25)
     attribute1= models.ForeignKey(Type, related_name = "att1_set+", default=None)
     attribute2= models.ManyToManyField(Type, related_name = "att2_set+", default=None)
     def __str__(self):             
       return self.metric_name
  </code></pre>
  
  <p>In my python interpreter:</p>
  
  <pre><code>&gt;&gt;&gt; from my_app.models import table1, table2
  &gt;&gt;&gt; t1 = table1 (name = "ty1", id = 0)
  &gt;&gt;&gt; t1.save()
  &gt;&gt;&gt; t2 = table1 (name = "ty2", id = 1)
  &gt;&gt;&gt; e1 = table2 (name = "as", attribute1 = t1)
  &gt;&gt;&gt; e1.save() 
  &gt;&gt;&gt; error aforementioned after .save
  </code></pre>
  
  <p>However when I exe: "manage.py sql myapp", I see for my table2:</p>
  
  <pre><code>CREATE TABLE "my_app_table2" (
  "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT,
  "name" varchar(25) NOT NULL,
  "attribute1_id" integer NOT NULL REFERENCES "myapp_table1" ("id")
  )
  </code></pre>