本文介绍了如何生成“创建表"? postgreSQL中现有表的sql语句的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我已经在postgreSQL中创建了一个表.我想看看用于创建表的SQL语句,但无法弄清楚.
I have created a table in postgreSQL. I want to look at the SQL statement used to create the table but cannot figure it out.
如何通过命令行或SQL语句获取Postgres中现有表的create table
SQL语句?
How do I get the create table
SQL statement for an existing table in Postgres via commandline or SQL statement?
推荐答案
pg_dump -t 'aschema.atable' --schema-only database-name
更多信息-在手册中.
这篇关于如何生成“创建表"? postgreSQL中现有表的sql语句的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!