On Fri, Jan 2, 2009 at 2:45 PM, hotani <hot...@gmail.com> wrote: > > Could this be a problem with the editable=False setting? >
Yes, sorry, I did not notice you had set that on one of the fields involved in the unique check. > The record I am attempting to duplicate is a duplicate office/county/ > case_no entry. However, it is also a duplicate county/case_no. It > seems like even with the form validation ignoring 'office' it would > catch the county/case_no dupe? > No, if any of the fields involved in unique_together are not present in cleaned_data during form validation (the editable=False one is not) then the check cannot be performed. county/case_no may be a dupe but without a value to check for office the form validation cannot determine if the three together are going to be unique. > I tried changing the Meta class to unique_together= > ("county","case_no") but no change. > I don't understand this. When I try your model code and only specify these two in unique_together I get a form-level validation ('Case with this County and Case no already exists.') error trying to specify a duplicate county/case_no. Karen --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---