Dataset Filtering
I want to filter a dataset (an ADOQuery) with the following:
If I change the OR to AND then it parses just fine (obviously returning no results because Company can't be two values).
Does this mean that I can't mix both ANDs and ORs in the same filter?
QueryData.Filter := '((StockGroup >= ''01G'') and (StockGroup <= ''01K'')) and ((Company = ''WHIP'') or (Company = ''WALLACE''))';
However Fast Reports tells me that I can't do that -
As far as I can tell, the string is perfectly fine, and logical."Arguments are of the wrong type, are out of acceptable range, or in conflict with one another"
If I change the OR to AND then it parses just fine (obviously returning no results because Company can't be two values).
Does this mean that I can't mix both ANDs and ORs in the same filter?
Comments
suggest you try the same filter on a query in delphi to see if it works.