B
bob biris
I'm building a search screen for an invoicing system.
The screen contains 10 fields corresponding to the data layout in the
DB (MyQuery(InvoiceID, Date, Name,Email)). We run the query,return a
dataset and bind it to a datagrid.
So far so good.
In addition, there is a requirement of having the possibility to put
and OR key in the field (for example Name: John OR Tom).
for example:
InvoiceID: 102 OR 103
Name: John OR Tom
Date: 02/02/2004
Email: (e-mail address removed) OR (e-mail address removed)
We were thinking about running the same query (8 times in this case).
MyQuery(102,'John','02/02/2004',[email protected])
MyQuery(102,'John','02/02/2004',[email protected])
MyQuery(102,'Tom','02/02/2004',[email protected])
MyQuery(102,'Tom','02/02/2004',[email protected])
MyQuery(103,'John','02/02/2004',[email protected])
MyQuery(103,'John','02/02/2004',[email protected])
MyQuery(103,'Tom','02/02/2004',[email protected])
MyQuery(103,'Tom','02/02/2004',[email protected])
Any idea what algorithm could be used to be those queries?
The screen contains 10 fields corresponding to the data layout in the
DB (MyQuery(InvoiceID, Date, Name,Email)). We run the query,return a
dataset and bind it to a datagrid.
So far so good.
In addition, there is a requirement of having the possibility to put
and OR key in the field (for example Name: John OR Tom).
for example:
InvoiceID: 102 OR 103
Name: John OR Tom
Date: 02/02/2004
Email: (e-mail address removed) OR (e-mail address removed)
We were thinking about running the same query (8 times in this case).
MyQuery(102,'John','02/02/2004',[email protected])
MyQuery(102,'John','02/02/2004',[email protected])
MyQuery(102,'Tom','02/02/2004',[email protected])
MyQuery(102,'Tom','02/02/2004',[email protected])
MyQuery(103,'John','02/02/2004',[email protected])
MyQuery(103,'John','02/02/2004',[email protected])
MyQuery(103,'Tom','02/02/2004',[email protected])
MyQuery(103,'Tom','02/02/2004',[email protected])
Any idea what algorithm could be used to be those queries?