Joined: Fri Jul 28, 2006 4:32 am Posts: 9
|
Lo,
i've got the collection mapped as <set> in my class and whenever I do the Add(something) method over this collection - the NHibernate insert this object (row) into DB just by oneself (automatically) and the other hand when I force method Clear() over the collection [which remove all objects from collection] the NHibernate doesn't delete this object (row) from the mapped table. So the result is that there in DB is many many rows which should not be there...
I just need to save or update these objects manually in program - by saveOrUpdate() command. Auto update/insert/delete after Add()/Remove() is unwanted. Any idea why this happens to me or how to prevent it?
Thank you very much for your answers.
Last edited by lc on Mon Jul 31, 2006 12:29 am, edited 1 time in total.
|
|