Difference in stored procedure and user defined function, DOT NET Programming

What is the difference between Stored Procedure (SP) and User Defined Function (UDF)?

Some of major differences between a stored procedure and user defined are as follows:-

1.      The UDF can be executed by using the "SELECT" clause while SP's can not be.

2.      The UDF cannot be used in the XML FOR clause while the SP's can be used.

3.      The UDF does not return any output parameters while the SP's return output parameters.

4.      If there is an error in the UDF its stops executing. But in SP's it just ignores the error and moves to the next statement.

5.      The UDF cannot make permanent changes to the server environments while SP's can

6.      Change some of the server environment.

Posted Date: 9/24/2012 3:20:35 AM | Location : United States







Related Discussions:- Difference in stored procedure and user defined function, Assignment Help, Ask Question on Difference in stored procedure and user defined function, Get Answer, Expert's Help, Difference in stored procedure and user defined function Discussions

Write discussion on Difference in stored procedure and user defined function
Your posts are moderated
Related Questions
What is XML Text Reader? The "XmlTextReader" class helps to give fast access to streams of XML data in a forward-only and read-only manner. The XMLTextReader also checks if the

What is project management? Applying the knowledge, skills, techniques, tools in project and deliver project deliverable is a short definition of the project management. It's b

What is the use of data adapter? The Data adapter are the objects that connect one or more Command objects to a Dataset object. They give logic that would get data from the dat

What is .NET Framework? .NET Framework is a complete environment that permits developers to develop, run, and deploy the following applications:     Windows services

What is nested Classes? You can access an array using the INDEX value of that array, but how many times you know the real value of the index. The Hashtable provides a way of ac

Need Report Generation in SQL / .NET Project Description: Prepare a report generation web page by pulling information from an SQL Database. Filter parameters per report :

Which namespaces are required to enable the use of databases in ASP.NET pages? The following namespaces are required to enable the use of databases in ASP.NET pages:     Th


What are Attributes?  Attributes are declarative tags in code that insert additional metadata into an assembly. There exist two types of attributes in the .NET Framework: Prede

Script for auto seating poker Project Description: Not just like that though. I need a similar program that can scan during poker lobbys (pokerstars, ipoker, full tilt and on