This question is locked. New answers and comments are not allowed.
Hello,
i create a new Instance from a Domain Class Object.
I add this Object to the DataContext and when i discard the changes with the following code
dbContext.FlushChanges();
if (dbContext.HasChanges == true)
{ dbContext.ClearChanges(); }
dbContext.SaveChanges();
and create a new Instance with the same Guid (PrimaryKey) and Add to Context
then i become the DuplicateKeyException Error Message
'ZIS_ING_BAU.Database.ZIS_SCHAEDEN_CHECK' with identity '400587378-c50c1778-6de2-447f-a9d3-0e1f48a6cd4c' already exists in the cache of the object scope.
I have no Second Level Cache in the BackendConfiguration and the Option CachePolicy is set to NoCache in the Domain Class.
What's wrong ?
i create a new Instance from a Domain Class Object.
I add this Object to the DataContext and when i discard the changes with the following code
dbContext.FlushChanges();
if (dbContext.HasChanges == true)
{ dbContext.ClearChanges(); }
dbContext.SaveChanges();
and create a new Instance with the same Guid (PrimaryKey) and Add to Context
then i become the DuplicateKeyException Error Message
'ZIS_ING_BAU.Database.ZIS_SCHAEDEN_CHECK' with identity '400587378-c50c1778-6de2-447f-a9d3-0e1f48a6cd4c' already exists in the cache of the object scope.
I have no Second Level Cache in the BackendConfiguration and the Option CachePolicy is set to NoCache in the Domain Class.
What's wrong ?