SQL IndexesPosted On: February 17, 2016
Indexes are extraordinary lookup tables that the database web crawler can use to accelerate information recovery. Basically, a list is a pointer to information in a table.
An index speeds up SELECT questions and WHERE provisions, yet it backs off information data, with UPDATE and INSERT proclamations. Lists can be made or dropped with no impact on the information.
Making a index includes the CREATE INDEX proclamation, which permits you to name the list, to determine the table and which section or segments to list, and to show whether the list is in rising or plunging request.
The CREATE INDEX Syntax:-
CREATE INDEX index_name ON table_name;
Single-Column Indexes Syntax:-
CREATE INDEX index_name ON table_name (column_name);
Unique Indexes Syntax:-
CREATE UNIQUE INDEX index_name on table_name (column_name);
Composite Indexes Syntax:-
CREATE INDEX index_name on table_name (column1, column2);
DROP INDEX Syntax:-
DROP INDEX index_name;