New answers tagged

2

I'd imagine that all of them are processed in a 'serial' way which may reduce performance compared to tables that doesn't need to access that number. In theory, yes. In practice, you would have to measure the effect to know if it is important. The current rowversion value is cached in memory and atomically updated using a cmpxchg instruction (in ...


0

The UPDLOCK will prevent a subsequent call from reading an order that has already been picked up, but won't allow that subsequent call from reading others because it will wait to read all the rows that fit the criteria and you have explicitly told the engine that you intend to update them in this transaction. If you add a READPAST hint as well, it will ...


0

DROP SCHEMA would attempt obtaining exclusive use of the schema first, so it would only actually manage to drop the schema when PostgreSQL is done retrieving data from ongoing queries. Further queries would likely be locked until the end of the transaction in your question. Queries accessing tables in the prod schema may fail after this transaction is ...



Top 50 recent answers are included