google-code-export / yabi

Automatically exported from code.google.com/p/yabi
0 stars 1 forks source link

Make use of the new on_delete directive in foreign keys #105

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
{{{
IntegrityError at /admin/yabi/tool/132/delete/
update or delete on table "yabi_toolparameter" violates foreign key constraint 
"yabmin_toolparameter_input_extensions_toolparameter_id_fkey" on table 
"yabi_toolparameter_input_extensions"
DETAIL:  Key (id)=(1587) is still referenced from table 
"yabi_toolparameter_input_extensions".
}}}

When deleting a tool that uses an extension that is used by another tool you 
get an error. I think this can be solved with on_delete now that we have 1.3:

https://docs.djangoproject.com/en/dev/topics/db/queries/#deleting-objects

Original issue reported on code.google.com by amacgregor on 7 Dec 2011 at 3:50

GoogleCodeExporter commented 9 years ago
Issue 191 has been merged into this issue.

Original comment by amacgregor on 18 Apr 2012 at 3:24

GoogleCodeExporter commented 9 years ago
Please tackle the issue in 191 at the same time.

Original comment by amacgregor on 18 Apr 2012 at 3:25

GoogleCodeExporter commented 9 years ago
Fixed 191 using on_delete directive. Can not reproduce above error.

Original comment by amacgregor on 16 May 2012 at 7:19