Set - 8

Question 26 :

What is the difference between a return parameter and an OUTPUT parameter?

Answer :

If the applicant is able to answer this question correctly, the odds are good that they have some experience working with stored procedures.
A return parameter is always returned by a stored procedure, and it is meant to indicate the success or failure of the stored procedure. The return parameter is always an INT data type.
An OUTPUT parameter is designated specifically by the developer, and it can return other types of data, such as characters and numeric values. (There are some limitations on the data types that can be used as output parameters.) You can use multiple OUTPUT parameters in a stored procedure, whereas you can only use one return parameter.


Question 27 :

What is a correlated sub-query? How can these queries be useful?

Answer :

The more seasoned developer will be able to accurately describe this type of query. A correlated sub-query is a special type of query containing a sub-query. The sub-query contained in the query actually requests values from the outside query, creating a situation similar to a loop. You can find a more detailed description as to how these special types of queries work in this article.