Re: Adding SHOW CREATE TABLE
От | Nathaniel Sabanski |
---|---|
Тема | Re: Adding SHOW CREATE TABLE |
Дата | |
Msg-id | CAFEN2wxg0Vtj1gvk6Ms0L2CAutbycyxHZPiZSpW7eLsBc6VGnA@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Adding SHOW CREATE TABLE (Nathaniel Sabanski <sabanski.n@gmail.com>) |
Ответы |
Re: Adding SHOW CREATE TABLE
|
Список | pgsql-general |
> Perhaps a bit more discussion about what exactly the use-case is would
> be helpful- what would you use this feature for?App writers: To facilitate table creation and simplify schema verification, without relying on a GUI tool or ORM (or system calls out to pg_dump).
Tool writers: Would drastically cut down the implementation time and complexity to support Postgres. I am one of the devs of Piccolo ORM (Python lib supporting Postgres) and we have a lot of code dedicated to re-generating the CREATE TABLE statements (creation, during migrations, etc) that could be done better by Postgres itself.
Ecosystem cohesion: SHOW CREATE TABLE has already been implemented in CockroachDB, a popular Postgres derivative.
Moving to Postgres: It would help ease migrations for developers wanting to move from MySQL / Percona / MariaDB to Postgres. Also it's a nice developer experience to see how Postgres generates X table without extra tooling.
The intention of SHOW CREATE TABLE is not to replace the existing suite of \d in psql but rather to be a developer friendly complement within SQL itself.
В списке pgsql-general по дате отправления: