Re: improve performance of pg_dump with many sequences - Mailing list pgsql-hackers

From Nathan Bossart
Subject Re: improve performance of pg_dump with many sequences
Date
Msg-id ZpgV32NTM0ADvJop@nathan
Whole thread Raw
In response to Re: improve performance of pg_dump with many sequences  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: improve performance of pg_dump with many sequences
List pgsql-hackers
On Wed, Jul 17, 2024 at 02:59:26PM -0400, Tom Lane wrote:
> Nathan Bossart <nathandbossart@gmail.com> writes:
>> On second thought, I worry that this change might needlessly complicate the
>> pg_sequences system view.  Maybe we should just add a
>> pg_sequence_get_tuple() function that returns everything in
>> FormData_pg_sequence_data for a given sequence OID...
> 
> Uh ... why do we need a function, rather than just
> 
> select * from pg_sequence

We can use that for dumpSequence(), but dumpSequenceData() requires
information from the sequence tuple itself.  Right now, we query each
sequence relation individually for that data, and I'm trying to find a way
to cut down on those round trips.

-- 
nathan



pgsql-hackers by date:

Previous
From: Alexander Lakhin
Date:
Subject: Re: [EXTERNAL] Re: Add non-blocking version of PQcancel
Next
From: Tom Lane
Date:
Subject: Re: improve performance of pg_dump with many sequences