SQL TOP - Overview, syntax

          

SQL TOP


SQL TOP - Introduction and syntax 

<<Previous  Next>>

SQL - Dec 03, 2008 at 18:00 PM by Rajmeet Ghai

Explain the SQL TOP statement. Write SQL syntax for the SQL TOP statement along with an example.

TOP clause is used to specify the number of records to return. Usually used for large tables.

Syntax:
SELECT TOP number|percent column_name(s) FROM table_name

Example:
SELECT TOP 2 * from employee


<<Previous  Next>> 

Also read

What is RAID (Redundant Array of Inexpensive disks)? Explain its level.

RAID is a mechanism of storing the same data in different locations. Since the same data is stored, it is termed as redundant............

What are the rules to use the ROWGUIDCOL property to define a globally unique identifier column?

Answer - A table can have only one ROWGUIDCOL column......

Describe when checkpoints are created in a transaction log.

Answer - It is created when CHECKPOINT statement is executed.......

What is transact-SQL? Describe its types?

Answer - SQL Server Provides three types of Transact-SQL statements namely DDL, DCL, and DML....

Define database objects.

Answer - SQL Server database stores information in a two dimensional objects of rows and columns called table......

What is index? Define its types.

Answer - Index can be thought as index of the book that is used for fast retrieval of information. Index uses one or more column index keys and pointers to the record to locate record.........



Write your comment - Share Knowledge and Experience


 
Latest placement tests
Latest links
 
Latest MCQs
» General awareness - Banking » ASP.NET » PL/SQL » Mechanical Engineering
» IAS Prelims GS » Java » Programming Language » Electrical Engineering
» English » C++ » Software Engineering » Electronic Engineering
» Quantitative Aptitude » Oracle » English » Finance
Home | About us | Sitemap | Contact us | We are hiring