-
Type: Improvement
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 0.5, 0.7, 0.9, 1.0
-
Component/s: None
-
None
-
Environment:All
-
Fully Compatible
When building a query with the query builder, some combinations throw an InvalidOperationException because the query underlying structure is a document, for instance:
Query.Or(
Query.EQ("name", "Flav"),
Query.EQ("name", "Flavien"),
Query.EQ("value", "Flavien")));
Throws an exception because the "name" attribute is defined twice on the document. This makes sense for a document, but doesn't for a query. The query builder should process the query to turn it seamlessly into a document, and not throw those kind of exceptions.
Also combining ORs inside ANDs should work, even if that is not supported by the engine, as the driver could change a query to its disjunctive form ( OR(AND(x, y), AND(a, b)) ), so that it is accespted by the engine.