Thread: A few questions:

A few questions:

From
"Christopher Kings-Lynne"
Date:
1. Did that fix to not allow cluster on partial and non-null indexes get
backpatched?

2. How can I deliberately cause a deadlock in order to test some code?

Chris



Re: A few questions:

From
Bruce Momjian
Date:
Christopher Kings-Lynne wrote:
> 1. Did that fix to not allow cluster on partial and non-null indexes get
> backpatched?

Yes, I see it in 7.3.X CVS.

> 2. How can I deliberately cause a deadlock in order to test some code?

Sure:CREATE TABLE t1(x int);CREATE TABLE t2(x int);INSERT INTO t1 VALUES (1);INSERT INTO t2 VALUES (1);CLIENT
1:BEGIN;UPDATEt1 SET x=2;CLIENT 2:BEGIN;UPDATE t2 SET x=2;UPDATE t1 SET x=1; -- blocksCLIENT 1:UPDATE t2 SET x=2;
 

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073