Create Simple & Composite Index In DBMS With Examples Explain, How To Create Simple & Composite Index

An index can be created on one or more columns.
Based on the number of columns included in the index, an index can be:
simple index
Composite index
Create Simple Index
An index created on a single column of a table is called simple index.
Syntax:
CREATE INDEX index_name
ON table_name (column_name);
Example:
CREATE INDEX idx_client_no
ON sales_order (Client_no);
Create Composite Index
An index created on more than one column it is called Composite index.
Syntax:
CREATE INDEX index_name
ON table_name (column_name,column_name);
Example:
CREATE INDEX idx_client_no
ON sales_order (Order_no, Client_no);
The column included in the index can have duplicate values.

0 comments:
Post a Comment
Thanks For Your Comment. We Get Back To You As Soon As Possible.