I'm wondering if its possible to "pause" a clustered index whenever bulk data is being written?
The reason is that:
I don't mind if the clustered index is rebuilt overnight, eg from 1am to 6am.
You can't disable a clustered index and still use the table.
Since the clustered index IS THE TABLE having it disabled means you can't access any of the data.
The data rows of the disabled clustered index cannot be accessed except to drop or rebuild the clustered index.
You can...
DROP
all indexes (including clustered) and insert, then CREATE
them overnight. This will render the table basically unusable, though. My preferred solution for this is a little more complicated:
INSERT
into a staging table that has the same clustered index key as your target table INSERT
from staging into target overnight and update indexes as needed then
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.