Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Changing PK from non-clustered to clustered
Message
 
 
À
06/07/2016 18:57:13
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Divers
Thread ID:
01637980
Message ID:
01637995
Vues:
46
First, thank you for your ok (I am not saying this facetiously; I trust you and others' expertise on this topic).
Yes, I know (read about it) that clustered index is like "sort" in VFP. And when I changed the PK from the non-clustered to clustered (on a sample table of about 500,000 rows), it took about 3-4 minutes to process. SQL Server - if I understand it correctly - had to build this clustered index and then create/update all non-clustered indexes.

>Based on that, you *should be* ok to make it a clustered index. One thing I haven't seen mentioned here. A clustered index is really a physical storing of the data in index order. You can insert, but it could mean rewriting a large portion of data.
>
>>The ID is an Identity column. If a user creates an order it is (ID) automatically set to the next ID sequential number. If user does not save the newly created record, the "missed" number will never be inserted.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform