can i pass a table to stored procedure

I do want to do a bulk insert into database, like 2000 records at a time. Can I pass a datatable to stored procedure and then insert them into destination table all at a time.
LVL 3
cognos79Asked:
Who is Participating?
 
Einstine98Commented:
I normally do it with XML documents...

1. Pass your data as an xmal document(table)...
2. Parse it to a temp table.
3. insert/update or whatever...

Will post you a link soon...
0
 
devsolnsCommented:
Are you doing this load from another application or through TSQL?  This is mainly a design question.  If this is being done over and over again you may want to do some type of bulk load (see http://www.sqlteam.com/item.asp?ItemID=3207).  Other wise ADO (in .NET) will handle this insert pretty easily without a major datbase performance impact.

Hope this helps.

--DS
0
 
cognos79Author Commented:
Einstine98 can you post the link please....
0
 
Einstine98Commented:
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.