Common SQL Interview Questions for Freshers
A primary key is a column in a table whose values uniquely identify the rows in the table. The primary key is chosen from this list of candidates based on its perceived value to the business as an identifier. A primary key value: Must uniquely identiy the row; cannot have NULL values; Should not change over the time; and Should be as short as possible. A candidate key is a key that uniquely identifies rows in a table . Any of the identified candidate keys can be used as the table's primary key . Candidate keys that are not part of the primary key are called alternate keys . One can describe a candidate key as a super key that contains only the minimum number of columns necessary to determine uniqueness. An alternate key is any candidate key that is not the primary key . Alternate keys are sometimes referred to as secondary keys. What is the definitions between stored procedures and functions? Fu...