Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 How to return a table from SQL server stored procedure

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2006-05-26 : 08:56:15
Ramesh writes "Hi All,
Is it possible to return a table from a stored procedure apart from returning single variable of any data type.
I need to make use of it my web application.Its very urgent.

Thanks in Advance
Ramesh."

robvolk
Most Valuable Yak

15732 Posts

Posted - 2006-05-26 : 08:57:31
Yes, just put the SELECT statement you want in the procedure:

CREATE PROCEDURE myProc AS
SET NOCOUNT ON
SELECT * FROM myTable WHERE col1=123
Go to Top of Page
   

- Advertisement -