Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Passing Multiple Values to a Single Parameter?
Message
 
 
To
21/09/2004 20:56:15
General information
Forum:
Microsoft SQL Server
Category:
Stored procedures, Triggers, UDFs
Miscellaneous
Thread ID:
00943913
Message ID:
00944819
Views:
28
This message has been marked as the solution to the initial question of the thread.
Try
CREATE PROCEDURE My1stSProc
@ListParam AS varchar(100)
AS
DECLARE @Sql nvarchar(4000)
SET @Sql = 'SELECT ItemID, ItemDesc  FROM dbo.ItemMaster' + 
  ' WHERE ItemID IN (' + @ListParam + ')' 
EXECUTE(@Sql)
>CREATE PROCEDURE My1stSProc
>@List char(100)
>as
>
>SELECT ItemID, ItemDesc
>FROM dbo.ItemMaster
>Where ItemID in (@List)
>GO
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform