| From: | Philip Warner <pjw(at)rhyme(dot)com(dot)au> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: pg_dump not dumping default_text_search_config WAI? |
| Date: | 2025-11-09 06:15:10 |
| Message-ID: | A1B34FC7-6299-4FCC-A57B-73A6A342EC97@rhyme.com.au |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On 2025-11-09 04:06, Tom Lane wrote:
> Philip Warner <pjw(at)rhyme(dot)com(dot)au> writes:
>> I just got bitten by dumping and restoring a database to a new cluster,
>> and the default_text_search_config was not copied for the database.
>
>> A check of the dump file shows no 'ALTER DATABASE' command.
>
> IIRC you'd need to use --create to prod pg_dump to produce
> a CREATE DATABASE command as well as any database-level
> ALTER commands.
Is that a good approach? The --create option should create the DB, yes. But...DB settings should, IMO, be done as part of the normal state dump/restore
ie. If I have previously issued a "create database" then a pg_restore should be able to create a matching database.
Would there be any appetite for a patch to at least implement this as an option? Which leads to setting other config parameters and the settings for ALLOW_CONNECTIONS and CONNECTION LIMIT.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
| From | Date | Subject | |
|---|---|---|---|
| Next Message | cca5507 | 2025-11-09 07:50:29 | Re: Use bsearch() instead of a manual binary search in syscache.c |
| Previous Message | Andres Freund | 2025-11-09 03:21:20 | Re: MSVC: Improve warning options set |