Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using LIKE @Parameter% with multi values

Status
Not open for further replies.
Jun 23, 2008
55
GB
Hi

I have a report that needs to select records where one field starts with the selected parameter value(s)

It works with just one value selected, using

(CR_CLIENTS.Status_Ref LIKE @NEET + '%')

but I can't seem to get the syntax right to allow multi values.

Is there a way to do this?

Thanks for reading
Annie
 
mmmm.....nasty

Will probably have to split the parameter in the SQL to its component parts (elements of the parameter array) and create multiple OR statements with LIKE

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top