1 dimensional array as input parameter to stored procedure

Anyone any code samples of how to pass a one dimensional array (70 elements) from VB into a SQL Server & stored procedure.

TIA

Regards
GK
LVL 5
GeoffKellAsked:
Who is Participating?
 
nigelrivettConnect With a Mentor Commented:
Here are some articles on the CSV option.

http://www.sqlteam.com/item.asp?ItemID=637

0
 
nigelrivettCommented:
easiest ways are to create a csv string and parse it in the SP or to create a temp table in VB populate it and access it in the SP.
0
 
AlfaNoMoreCommented:
Check out the passing of a CSV to a stored procedure instead. I think you can then convert this csv into an array within the SP, but you won't be able to pass a variant type to an SP.
0
 
GeoffKellAuthor Commented:
Thanks - I expected that a delimited string would the way to go but needed a quick confirmation with, ideally, some code.

The link you provided did just the trick

Regards
GK
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.