-
Notifications
You must be signed in to change notification settings - Fork 1
Query API
donnyv edited this page Sep 1, 2013
·
9 revisions
Assumes the object property is an array and only returns collections where all supplied values are matched.
var db = new enosql.EnosqlDatabase(@"c:\temp\db.jdb");
var PeopleCollection = db.GetCollection<People>();
PeopleCollection.Find(EnosqlQuery.All("FirstName", new []{"tom", "jim", "donny"}));
Performs a strict equality test using ===.
var db = new enosql.EnosqlDatabase(@"c:\temp\db.jdb");
var PeopleCollection = db.GetCollection<People>();
PeopleCollection.Find(EnosqlQuery.EQ("FirstName", "Donny"));
Joins query clauses with a logical AND returns all documents that match the conditions of both clauses
var db = new enosql.EnosqlDatabase(@"c:\temp\db.jdb");
var PeopleCollection = db.GetCollection<People>();
PeopleCollection.Find(EnosqlQuery.And(
EnosqlQuery.EQ("FirstName", "Donny"),
EnosqlQuery.LikeI("LastName", "smi")
);