| From: | Manni Wood <manni(dot)wood(at)enterprisedb(dot)com> |
|---|---|
| To: | Jim Jones <jim(dot)jones(at)uni-muenster(dot)de> |
| Cc: | Nishant Sharma <nishant(dot)sharma(at)enterprisedb(dot)com>, Álvaro Herrera <alvherre(at)kurilemu(dot)de>, pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: [PATCH] Add pg_get_tablespace_ddl() function to reconstruct CREATE TABLESPACE statement |
| Date: | 2025-11-07 23:38:12 |
| Message-ID: | CAKWEB6p4N5V03KNHD_WPxZQyfZ=qTnDu=sXfD3ThQ40EQcpkfQ@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Fri, Nov 7, 2025 at 4:38 PM Manni Wood <manni(dot)wood(at)enterprisedb(dot)com>
wrote:
>
>
> On Fri, Nov 7, 2025 at 10:16 AM Jim Jones <jim(dot)jones(at)uni-muenster(dot)de>
> wrote:
>
>>
>>
>> On 07/11/2025 02:27, Manni Wood wrote:
>> > Attached v7 fixes problems in tests due to whitespace.
>>
>>
>> Since get_tablespace_loc_string returns a palloc'd string, I guess you
>> could pfree it after the if block. The same applies for spcowner, since
>> you're calling GetUserNameFromId() with noerr = false.
>>
>> For reference, see pg_get_indexdef_worker():
>>
>> ...
>> /*
>> * If it has options, append "WITH (options)"
>> */
>> str = flatten_reloptions(indexrelid);
>> if (str)
>> {
>> appendStringInfo(&buf, " WITH (%s)", str);
>> pfree(str);
>> }
>> ...
>>
>>
>> Thanks
>>
>> Best, Jim
>>
>
> Hello, Álvaro and Jim!
>
> I have incorporated both of your suggestions into this pair of v8 patches.
>
> Let me know what you think.
> --
> -- Manni Wood EDB: https://www.enterprisedb.com
>
Alas, the build https://commitfest.postgresql.org/patch/6175/ now fails,
and I cannot reproduce on my machine. Obviously there will be a v9...
--
-- Manni Wood EDB: https://www.enterprisedb.com
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Thomas Munro | 2025-11-07 23:47:56 | Re: IO in wrong state on riscv64 |
| Previous Message | Tomas Vondra | 2025-11-07 23:17:30 | Re: contrib/pg_stat_tcpinfo |