Print
Add To Favorites
Email To Friend
Rate This Article
|
Pass Tables to Stored Procedure / Table Valued Parameter
|
Published:
06 Nov 2009
|
Abstract
When we have to pass multiple rows of data to SQL Server, the developers either have to send one row at a time or come up with other workarounds to meet requirements like using XML to pass data, which is complex and tedious to use. There is a SQLBulkCopy object available in .NET to send multiple rows of data to SQL Server at once, but this still cannot be passed to a stored procedure.
SQL Server 2008 provides a new feature called "Table-Valued Parameters". This provides us the ability to easily pass a table to a stored procedure from T-SQL code or from an application as a parameter. |
 |
by Aamod Thakur
Feedback
|
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days):
6116/
317
|
|
|
|
| Introduction |
When we have to pass multiple rows of data to SQL Server the
developers either have to send one row at a time or come up with other
workarounds to meet requirements like using XML datatype to pass data which is
a bit complex and tedious to use. Also there is a SQLBulkCopy object available
in .Net to send multiple rows of data to SQL Server at once, but the data still
can not be passed to a stored procedure.
|
|
|
|
|
Article Feedback
User Comments
Title:
good article
Name:
manas sahu
Date:
12/23/2009 8:46:08 AM
Comment:
Good article but not what i m looking for.
|
Title:
Title misleading
Name:
Chin Kiat
Date:
12/8/2009 1:26:10 AM
Comment:
The title is not match to what you are posting...i understand why jeewan disaapointed =(
|
Title:
disappointed
Name:
jeewan
Date:
11/20/2009 5:48:05 AM
Comment:
Not what i am searching http://pictube1.blogspot.com/
|
|
|
|
|
|