Changes between Initial Version and Version 1 of Ticket #13492
- Timestamp:
- May 7, 2010, 9:58:01 PM (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #13492
- Property Resolution → invalid
- Property Status new → closed
-
Ticket #13492 – Description
initial v1 4 4 I have applied custom SQL for that constraint. 5 5 6 As I am bulk loading the table, I am making use of get_or_create(field0 __iexact=value0, field1=value1).6 As I am bulk loading the table, I am making use of get_or_create(field0!__iexact=value0, field1=value1). 7 7 When I use this invocation, field0 ends up being set as null. 8 8 9 If I invoke it as get_or_create(field0 __iexact=value0, field0=value0, ...)9 If I invoke it as get_or_create(field0!__iexact=value0, field0=value0, ...) 10 10 I eventually have a constraint error. 11 11 12 I would expect a FieldError if field0 __iexact were not permitted, and I would expect the fieldname to be calculated from field0__iexact if it were permitted.12 I would expect a FieldError if field0!__iexact were not permitted, and I would expect the fieldname to be calculated from field0!__iexact if it were permitted. 13 13 14 14 I am currently avoiding the problem by catching an exception on psycopg2.IntegrityError, but that does not seem to be the right solution.