You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I know the question has been asked many times but it seems to make sense:
We often have to replicate data between different systems where we want to keep the original guids of the data. when wanting to do so using Nhibernate, we cannot use the SaveOrUpdate possibility since there is only the option of:
always save
Always update
save when id = null
save when id = null or "value"
So basically, if you want to use SaveOrUpdate, you cannot assign your own guid's as primary keys.
In data replication situations (for example receiving data from another application using a messagequeue) you have to first check if an object is already present and then decide to save or update.
It would be nice to have an option saying "try" which would do this for you (so query the database/persistence to see if an object with the given id already exists, if not= save, else = update)
The text was updated successfully, but these errors were encountered:
Michel Van Hoof created issue - 13/Nov/09 9:46 PM
The text was updated successfully, but these errors were encountered: