Can store procedure call by user define function in SQL
server?
Answer Posted / samba shiva reddy . m
sorry the last post was not correct.
yes we can call stored procedure in User defined function.
1.Stored procedures are pree compiled and functions are not pree compiled it will execute at run time.
2.Functions cannot affect the state of the database which means we cannot perform insert,delete,update and create operations on the database.
Stored Procedures can affect the state of the database by using insert,delete,update and create operations.
3.Procedure can return zero or n values whereas function can return one value which is mandatory.
4.Procedures can have input,output parameters for it whereas functions can have only input parameters.
5.Functions can be called from procedures and in select statement and whereas procedures cannot be called from function or select statement.
6.A Function returns 1 value only. Procedure can return
multiple values (max 1024).
7. Stored procedure returns always integer value by default
zero. Whereas function returns type could be scalar or
table or table values.
| Is This Answer Correct ? | 8 Yes | 2 No |
Post New Answer View All Answers
What are the system database in sql server 2005?
How to include date and time values in sql statements?
What is SQL Azure Fabric?
Explain system scalar functions?
Explain linked server in sql?
Explain difference between cross join and full outer join?
Can you edit the .rdl code associated with a linked report?
what is the main function of a query parameter?
What type of locking occurs during the snapshot generation? : sql server replication
Distinguish between nested subquery and correlated subquery?
What is Extended user-defined?
What are the instances when triggers are appropriate?
What is 3nf normalization form?
What is precedence constraint?
Suppose you want to implement the following relationships while designing tables. How would you do it?a.) One-to-oneb.) One-to-manyc.) Many-to-many