G
Guest
Hi, I'm trying to build a stored procedure to run in a SQL 2000 environment.
I'd like to search for invoices by invoice type. The user interface for
invoice type has a checked listbox where multiple selections are allowed.
WHERE SS.RouteGroup IN (@RouteGroup)
If I pass a single selection to the procedure using the following statement,
I get the correct list of pest control invoices.
exec ske_getrimms @DateStart = '1/24/2005', @DateEnd = '1/24/2005', @Branch
= 'Boise', @RouteGroup = 'Pest Control'
However, I don't get any results if I also try to filter for multiple route
groups as follows.
exec ske_getrimms @DateStart = '1/24/2005', @DateEnd = '1/24/2005', @Branch
= 'Boise', @RouteGroup = 'Pest Control, Irrigation, Mowing'
I can't seem to find a way of passing multiple selections to the stored
procedure through a parameter. Am I missing something here?
Thanks,
Andre Ranieri
I'd like to search for invoices by invoice type. The user interface for
invoice type has a checked listbox where multiple selections are allowed.
WHERE SS.RouteGroup IN (@RouteGroup)
If I pass a single selection to the procedure using the following statement,
I get the correct list of pest control invoices.
exec ske_getrimms @DateStart = '1/24/2005', @DateEnd = '1/24/2005', @Branch
= 'Boise', @RouteGroup = 'Pest Control'
However, I don't get any results if I also try to filter for multiple route
groups as follows.
exec ske_getrimms @DateStart = '1/24/2005', @DateEnd = '1/24/2005', @Branch
= 'Boise', @RouteGroup = 'Pest Control, Irrigation, Mowing'
I can't seem to find a way of passing multiple selections to the stored
procedure through a parameter. Am I missing something here?
Thanks,
Andre Ranieri