-
Type:
Task
-
Resolution: Cannot Reproduce
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Environment:MongoDB runs on ubuntu server lts 12, development environment is Windows 2008 R2 Ent Server with VS 2010
-
None
-
None
-
None
-
None
-
None
-
None
-
None
When I want to upsert my record I get duplicate key error.
The Code:
var update_query = Query.And(
Query.EQ("Id", item.Id) , ,
Query.EQ("UserId", item.UserId),
Query.EQ("Email",item.Email)
);
var resxs= coll.Update(update_query,
Update.Replace(item),
UpdateFlags.Upsert
);
But when I remove "Id" criteria,the code works and doing upset.
Is there anything I am missing.
thnx