"Heng Sun" <[EMAIL PROTECTED]> writes: > But my question is: will this completely get around the problem of server > corrupt? In particular, if in a transaction, the "nextval" is called on a > sequence different from the sequence we are trying to drop, would there be a > problem? My tests showed NO problem in this situation. Also the analysis > from Tom Lane seems confirming this. But I am still not sure on this.
I believe there is no problem in that case. The AccessShareLock held by the other guy will actually hold off your attempt to drop the sequence until he commits. The reason we can see the bug in the single-backend case is that your own AccessShareLock won't block you from getting the exclusive lock needed to drop the sequence. regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])