"Dan Armbrust" <daniel.armbrust.list@gmail.com> writes:
> On windows, if I attempt to drop a database when I am purposefully
> holding a connection open to the DB, it fails immediately - ~ 100 ms.
> On linux, if I do the same thing, the drop database command takes
> upwards of 4 seconds before it gives up, and says it can't drop the
> DB.
> Is this expected?
I think you are comparing different PG versions. Recent releases will
delay a bit to see if the competing connection disappears.
> Is there some way I can control how long it will
> block the drop command, waiting for the DB to not be in use?
No.
regards, tom lane