On Jul 6, 2007, at 5:50 PM, Koen Bok wrote:

>
> I have a strange situation. If someone _really_ needs to know why I
> could explain.
>
> When an object gets deleted by SQLAlchemy, it's related objects are
> getting updated setting their foreign keys referring to the deleted
> items to NULL. But what if I don't want that to happen? Viewonly is
> not an option here, as I need to be able to make changes.
>

it wants to maintain referential integrity.  if you werent using  
SQLite, you'd get an error on any other database if it were not set  
to NULL.   that the foreign key value can store a value which doesnt  
exist otherwise seems to imply youre setting it manually, in which  
case "viewonly" could still work for you.  we dont have an option  
right now for it to populate foreign keys but to not clear them out  
(also have gone this far without anyone *truly* needing it....).

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to