Re: Adding SHOW CREATE TABLE

Stephen Frost <sfrost@snowman.net>

From: Stephen Frost <sfrost@snowman.net>
To: Nathaniel Sabanski <sabanski.n@gmail.com>
Cc: pgsql-general@lists.postgresql.org
Date: 2023-05-12T14:40:38Z
Lists: pgsql-hackers, pgsql-general
Greetings,

Please don't top-post on these lists.

* Nathaniel Sabanski (sabanski.n@gmail.com) wrote:
> I believe most users would anticipate a CREATE TABLE statement that aligns
> with the currently installed version- this is the practical solution for
> the vast majority.

Perhaps a bit more discussion about what exactly the use-case is would
be helpful- what would you use this feature for?

> In situations where a CREATE TABLE statement compatible with an older
> version of Postgres is required, users can opt for an additional step of
> using tools like pg_dump or an older version of Postgres itself. This
> allows them to ensure compatibility without compromising the practicality
> of the process.

The issue is really both older and newer versions, not just older ones
and not just newer ones.

To the extent you're interested in this, I pointed out where you could
go look at the existing code as well as an idea for how to move this
forward.

Thanks,

Stephen