View Full Version : Query with parameter


Ron Wilson
02-12-2008, 07:51 PM
Hi,

I want to create a query whereby the user can enter the part of a name (via a pop up) to be searched and all results with that searched part will show. Would appreciate any help. Thanks!!

m.shakeebahmed
02-13-2008, 03:24 AM
it would be something like this

PARAMETERS inputstr Text ( 255 );
SELECT Table.name
FROM Table
WHERE (((Table.name) Like '*' & [inputstr] & '*'));

neileg
02-13-2008, 03:43 AM
What I would do is populate a combo box in a form with all the possible values for the name. Standard behaviour of a combo is that it 'zooms' to the required value as you type. Then you can use the selected value as the parameter for your query