What you want to see on DotNetFunda.com ?
DotNetFunda.Com Logo
Twitter TwitterLinkedIn
YouTubeGoogle
 Online : 18982 |  Welcome, Guest!   Register  Login
 Home > Forums > ASP.NET > How to declare arrray inside storedprocedure ...
Oswaldlily

How to declare arrray inside storedprocedure

Replies: 3 | Posted by: Oswaldlily on 6/4/2012 | Category: ASP.NET Forums | Views: 314 | Status: [Member] | Points: 10  


How to declare arrry inside storedprocedure

In codebehind
function.Storedprocedure1(_invoiceNo, _pNo[], _Query[],_flag);

In StoredProcedure

Alter Procedure Storedprocedure1
(
_invoiceNo as nvarchar(20),
_pNo as ? ,
_Query as ? ,
_flag as nvarchar(20)
)


Reply | Reply with attachment | Alert Moderator

 Responses below this adGet hundreds of .NET Tips and Tricks videos

 Replies

CGN007
CGN007  
Posted on: 6/4/2012 5:54:59 AM
Level: Silver | Status: [Member] | Points: 25

http://www.codeproject.com/Articles/36394/Passing-an-Array-as-Parameter-to-SQL-Server-Proced
http://www.codeproject.com/Articles/17802/Use-Table-Valued-Functions-as-Arrays-in-SQL-Server

Oswaldlily, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

Ndebata
Ndebata  
Posted on: 6/4/2012 6:24:15 AM
Level: Starter | Status: [Member] | Points: 25

if you using SQL Server 2008 and above , you can pass a data table to store procedure.

1st create a table type in sql server
Then use this new type as a readonly parameter.
and you can use this parameter.

and from dot not pass a datatable

Oswaldlily, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

CGN007
CGN007  
Posted on: 6/23/2012 10:06:39 AM
Level: Silver | Status: [Member] | Points: 25

Mark as Answer if its helpful to you,that motivates...

Oswaldlily, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

Reply - Please login to reply


Click here to login & reply

Found interesting? Add this to:


 Latest Posts

Write New Post | More ...

About Us | Contact Us | The Team | Advertise | Software Development | Write for us | Testimonials | Privacy Policy | Terms of Use | Link Exchange | Members | Go Top
General Notice: If you find plagiarised (copied) contents on this page, please let us know the original source along with your correct email id (to communicate) for further action.
Copyright © DotNetFunda.Com. All Rights Reserved. Copying or mimicking the site design and layout is prohibited. Logos, company names used here if any are only for reference purposes and they may be respective owner's right or trademarks. | 5/22/2013 9:01:27 PM