dropdb --force
Filip Rembiałkowski <filip.rembialkowski@gmail.com>
From: Filip Rembiałkowski <filip.rembialkowski@gmail.com>
To: Pgsql Hackers <pgsql-hackers@postgresql.org>
Date: 2018-12-18T12:25:32Z
Lists: pgsql-hackers
Attachments
- postgresql-dropdb--force.20181218_01.patch (text/x-patch) patch
Hi, I propose a simple patch (works-for-me), which adds --force (-f) option to dropdb utility. Pros: This seems to be a desired option for many sysadmins, as this thread proves: https://dba.stackexchange.com/questions/11893/force-drop-db-while-others-may-be-connected Cons: another possible foot-gun for the unwary. Obviously this patch needs some more work (see TODO note inside). Please share opinions if this makes sense at all, and has any chance going upstream. The regression tests is simplistic, please help with an example of multi-session test so I can follow. Thanks, Filip
Commits
-
Add tests for '-f' option in dropdb utility.
- 8a7e9e9dad56 13.0 landed
-
Move pump_until to TestLib.pm.
- 290acac92b1d 13.0 landed
-
Add the support for '-f' option in dropdb utility.
- 80e05a088e4e 13.0 landed
-
Introduce the 'force' option for the Drop Database command.
- 1379fd537f9f 13.0 landed
-
Improve CREATE/DROP/RENAME DATABASE so that when failing because the source
- 4abd7b49f1e9 8.4.0 cited