can i write function in stored procedure and stored
procedure in function and nested procedure.Give one example
for each question?
Answer / dba
You cannot define stored procedures (SP) or user-define
functions (UDF) in a nested fashion. However, you can
execute SPs and UDFs inside of stored procedures. The
nesting is limited to 32 levels deep (A calls B, which calls
C, etc). So if a recursive call is used (A calls A), you
must have some method of stopping before 32 levels is exceeded.
You can call SPs and UDFs from inside of a UDF, but this
ability is quite limited. If a SP has any side effect, it
cannot be called. So, the SP cannot be used to return any
values to the function.
Is This Answer Correct ? | 3 Yes | 1 No |
Determine when to use stored procedure to complete sql server tasks?
How do you use a subquery to find records that exist in one table and do not exist in another?
What is the template in sql?
How can we delete a table in sql server?
Do you know the cursor types?
What is an active database?
PC(code, model, speed, ram, hd, cd, price) Find the hard drive sizes that are equal among two or more PCs.
How to insert data with null values?
How to edit table in sql server 2017?
About DTS usage ?
What is a rownum?
What are distinctive joins find as a part of sql?