Subject Simple parameter query question
Author mitch_landor
Not sure if this is a Delphi or IB question but here goes:

I want a query that always obtains the same columns from a table/s,
but which uses different parameters in different situations.

Example 1:
Return all rows

Example 2:
Customer ID = 44
Document Type = 25

Example 3:
Customer ID = all
Document Type = 25

I know that one can create a paramter in a query and then reference it
using parambyname, but how can I create a single query that will for
example allow CustomerID
sometimes to return "44" and sometimes to return all rows? What is the
parameter for "all"?

Really I'm looking for a way to use an "all" parameter so I can get
all result permutations using only one base query by always passing
all the possible parameters, rather than having to create lots of
separate queries.

Thanks

Mitch