[dba-SQLServer] Can't drop the PK from a table

Arthur Fuller fuller.artful at gmail.com
Tue Jun 17 11:38:09 CDT 2008


Thanks for the clarification.

Arthur

On Mon, Jun 16, 2008 at 7:31 PM, Asger Blond <ab-mi at post3.tele.dk> wrote:

> Arthur, sorry I didn't read your scenario close enough:
> "I have a table into which a process inserts 1300 rows every 10 minutes.
> Currently there are 34 million rows in the table."
>
> When rebuilding an index SQL Server normally locks the key, which will
> raise
> concurrency issues for your insert-process.
>
> To circumvent this issue you should use the option WITH ONLINE = ON, which
> will place the index rebuild-values into the tempdb database and apply them
> as allowed by concurrency.
>
> So this would be the statement:
>
> ALTER INDEX [PK_BESTSecurityLog] ON [dbo].[BESTSecurityLog] REBUILD WITH
> ONLINE = ON
>
> Asger
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> _______________________________________________
> dba-SQLServer mailing list
> dba-SQLServer at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/dba-sqlserver
> http://www.databaseadvisors.com
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> _______________________________________________
> dba-SQLServer mailing list
> dba-SQLServer at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/dba-sqlserver
> http://www.databaseadvisors.com
>
>



More information about the dba-SQLServer mailing list