What are classes of identifier?

What are classes of identifier? Explain each class with an example i.e. regular and delimited identifier.

There are two classes of identifier. These identifiers must contain 1 to 128 characters.

1. Regular identifiers: They follow the rules for the format of identifiers. They are not delimited when used in transact SQL statements.

Example:
Select * from table_name Where ID =110

2. Delimited identifiers: They follow the rules for the format of identifiers. They may or may not be delimited when used in transact SQL statements. They are enclosed either in (“) or ([])

Example:
Select * from [table_name] Where [ID] =110
What are the Rules for Regular Identifiers
Rules for Regular Identifiers: These rules are dependant on database compatibility level. For a compatibility level 90, following rules may apply.....
Define Subqueries
A subquery is a query within a query. These sub queries are created with SQL statements. These subqueries are embedded within SELECT, FROM or the WHERE clause........
Subqueries with IN and NOT IN
Sub Query Example with IN: Displays employees from employee table with bonus > 1000. Using IN first all employees are selected and compared to each row of the subquery.........
Post your comment