Hi,
What is Stored procedure in Database?
Thanks.
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
SenthilkumarPosted Mar 2, 2012, 6:51 AM
You can query the stored procedures list from the following query.
SELECT * FROM SYS.PROCEDURES
It has some advantages like
-Avoid sql injection
-Fast execution compare to the inline queries
-Multiple application can use the same procedures
-Permission can be set the stored procedure
-Business logics in the procedure can be changed with out modifying the source code and redeployment.
Satyapriya NayakPosted Feb 9, 2012, 12:44 AM
Its nothing but a set of T-SQL statements combined to perform a single task of several tasks. Its basically like a Macro so when you invoke the Stored Procedure, you actually
run a set of statements. Stored Procedure are the precompiled set of sql command.
Stored procedures means containing a precompiled block of code. if we call stored procedures they need not compiled, only execution takes place. With this advantage, work on database is less.Please refer the below link
http://www.c-sharpcorner.com/uploadfile/puranindia/stored-procedures/default.aspx
Thanks
Pravin MorePosted Feb 9, 2012, 12:43 AM
Have you ever written SQL statements, like inserts, selects, and updates? Then you have already written most of a stored procedure. A stored procedure is an already written SQL statement that is saved in the database. If you find yourself using the same query over and over again, it would make sense to put it into a stored procedure. When you put this SQL statement in a stored procedure, you can then run the stored procedure from the database's command environment .
Click Here for more information.
Thanks,
Pravin.