What is difference between function and procedure?
Answer Posted / gunesh
1.Function is mainly used in the case where it must return
a value. Where as a procedure may or may not return a value
or may return more than one value using the OUT parameter.
2.Function can be called from sql statements where as
procedure cannot be called from the sql statements.
3.Functions are normally used for computations where as
procedures are normally used for executing business logic.
4.You can have DML (insert, update, delete) statements in a
function. But, you cannot call such a function in a SQL
Query.
5.A Function returns 1 value only. Procedure can return
multiple values (max 1024).
6.Stored Procedure: supports deferred name resolution.
Example while writing a stored procedure that uses table
named tabl1 and tabl2 etc...But actually not exists in
database is allowed only in during creation but runtime
throws error Function won’t support deferred name
resolution.
7.Stored procedure returns always integer value by default
zero. whereas function return type could be scalar or table
or table values
8.Stored procedure is precompiled execution plan where as
functions are not.
9.A procedure may modify an object where a function can
only return a value The RETURN statement immediately
completes the execution of a subprogram and returns control
to the caller.
Is This Answer Correct ? | 13 Yes | 6 No |
Post New Answer View All Answers
how u will evaluate the tool for test automation?
how will you load the test cases in ddt?
how to use the regular expression for the below code-- swf("application name").swftreeview ("Treename").select"Medication;Pharmacy:56" There is a tree view window of the folder's ie Medication- >Pharmacy(sub folder)with 56 as count of records...The records can be different or if no records present in the specific folder..then it show "Paharmacy:-no records".Whe i record at the first time .....and try to rerun the same script with different records count say "pharmacy:800"..qtp is not regnizing it...therefore i want to user regular expression..but donot now how to use it and where to use...i have tried.... swf("application name").swftreeview ("Treename").select"Medication;Pharmacy:\*"..but it s of no use..plz help..me
Difference between copy to action and call to action?
In qtp, how you can get the last character from a string?
How are cgi programs, applets, javascripts, ActiveX components, etc. to be maintained, tracked, controlled, and tested?
Which recording modes need more memory?
What are main panes available in qtp test browser?
Why we use QTP ,We can use other tools like WR OrSilktest What r the options in Qtp that WR and Swilktest Does not have.
Discuss quicktest professional environment?
How will you compare keyword and expert view?
Hi All, I have QTP installed on my machine but the application under test is on remote machine. I need to automate the scenarios which consist of automatically enter the remote machine through IP address ,record the application in remote machine and run it also when played. Can some one tell how to record the application in remote machine.
Why do you create a text checkpoint on a Web application? What is the purpose of the Close method?
Hi, is it possible for recording shortcut key during record session? The application on which I am working is web based application. This application has several shortcut key associated with menu option. I have succesfully recorded all menu option but unable to record shortcut key.
Can we create a qtp test from qc?