Execute based on parameter

spec

Registered User.
Local time
Today, 13:28
Joined
Jun 9, 2005
Messages
12
Hi,

Based upon the parameter given i want to run different queries
i need to do the below in one query.

PARAMETERS Proj Text( 30 );
If proj="All"
Select * from TbProj
else
Select * from TbProj where Proj_ID=proj;

I want to build an access query like above.
I don't know whether it supports using IF statements.
how to do the above.

Thanks.
 
How about something like:

Select * from TbProj where Proj_ID=proj or proj='All';

???
 

Users who are viewing this thread

Back
Top Bottom