Indexing
Congratulations! You have provisioned and implemented an Azure SQL database. There are a lot of extra features that you need to learn in relation to SQL Server. A good book to start with is SQL Server 2017 Developer's Guide, by Dejan Sarka, Miloš Radivojević, and William Durkin. There is one topic that is too important to not devote some time to in this regard: indexing.
Roughly speaking, indexes make reading data from a database faster, but slow down writing to databases. So, you have to be careful with the indexes you create. But without indexes, you are almost sure to experience performance problems.
There are two basic kinds of indexes:
- Clustered indexes
- Nonclustered indexes
Clustered index
A clustered index could be described as an index-organized table. When you create a clustered index, you store the actual rows sorted on the index key in a structure called a B-Tree. The index is the table. A clustered index is not a structure...