#5662: get_or_create fails when there is a unique field and other values
----------------------------------------------------------+-----------------
   Reporter:  kenneth gonsalves <[EMAIL PROTECTED]>  |                Owner:  
nobody          
     Status:  new                                         |            
Component:  Database wrapper
    Version:  SVN                                         |           
Resolution:                  
   Keywords:  get_or_create                               |                
Stage:  Unreviewed      
  Has_patch:  0                                           |           
Needs_docs:  0               
Needs_tests:  0                                           |   
Needs_better_patch:  0               
----------------------------------------------------------+-----------------
Changes (by insin):

  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * needs_docs:  => 0

Comment:

 Isn't this why the defaults argument exists?

 {{{
 word, created = Word.objects.get_or_create(word=wd,
 defaults=dict(language=lng, rootword=rtwd, english=eng))
 }}}

 http://www.djangoproject.com/documentation/db-api/#get-or-create-kwargs

-- 
Ticket URL: <http://code.djangoproject.com/ticket/5662#comment:1>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to