|www.sum-it.nl > Courses|
> DB Design course > Method > 4. Implementation > Maak index
Nederlands · Search...
Create IndexDuring technical optimisation you designed indexes. Here you see how to create such an index, with the option cluster to sort the table.
|Introduction 1. Scope 2. Logical Design 3. Technical Optimisation Various DBMSses Create table Extra column End|
The options ASC (ascending, from low to high) and DESC (descending, from high to low) indicate the sorting of the index.
Most of the time you can leave this option out.
ExampleCREATE UNIQUE INDEX subscription_ID ON subscription ( taxNumber, newspaperName )
This creates an index with the name "subscription_ID" for the table subscription. The combination of taxNumber and newspaperName will be unique, can not occur double.