Re: [SQL] Rename Index - Deadlock

2010-03-16 Thread Scott Marlowe
On Tue, Mar 16, 2010 at 3:45 AM, Thomas Kenner wrote: > Hi, > > Each day I'm recreating the index my_index of the table my_table. Therefore I > create a new index my_index_new, drop the old index my_index, and rename the > new index: > ALTER INDEX my_index_new RENAME TO my_index; > > If an insert

Re: [SQL] Rename Index - Deadlock

2010-03-16 Thread Tom Lane
Thomas Kenner writes: > Each day I'm recreating the index my_index of the table my_table. Therefore I > create a new index my_index_new, drop the old index my_index, and rename the > new index: > ALTER INDEX my_index_new RENAME TO my_index; > If an insert or select statement is run at the same

[SQL] Rename Index - Deadlock

2010-03-16 Thread Thomas Kenner
Hi, Each day I'm recreating the index my_index of the table my_table. Therefore I create a new index my_index_new, drop the old index my_index, and rename the new index: ALTER INDEX my_index_new RENAME TO my_index; If an insert or select statement is run at the same time as the "ALTER INDEX ..