title: Django get_or_create raises Duplicate entry for key Primary with defaults
body: <p>Help! Can't figure this out! I'm getting a Integrity error on get_or_create even with a defaults parameter set.</p>
  
  <p>Here's how the model looks stripped down.</p>
  
  <pre><code>class Example(models.Model):model
      user            = models.ForeignKey(User)
      text            = models.TextField()
  
  def __unicode__(self):
      return "Example"
  </code></pre>
  
  <p>I run this in Django:</p>
  
  <pre><code>def create_example_model(user, textJson):
      defaults = {text: textJson.get("text", "undefined")}
  
      model, created = models.Example.objects.get_or_create(
              user=user, 
              id=textJson.get("id", None), 
              defaults=defaults)
  
      if not created:
          model.text = textJson.get("text", "undefined")
          model.save()
  
      return model
  </code></pre>
  
  <p>I'm getting an error on the get_or_create line:</p>
  
  <pre><code>IntegrityError: (1062, "Duplicate entry '3020' for key 'PRIMARY'")
  </code></pre>
  
  <p>It's live so I can't really tell what the input is.</p>
  
  <p>Help? There's actually a defaults set, so it's not like, this problem where they do not have a defaults. Plus it doesn't have together-unique. <a href="https://stackoverflow.com/questions/6974463/django-get-or-create-raises-duplicate-entry-with-together-unique">Django : get_or_create Raises duplicate entry with together_unique</a></p>
  
  <p>I'm using python 2.6, and mysql.</p>