pg_dump [ダンプしたいDB名] > [dumpファイルの名前]
ex) pg_dump mgc -U test -p 19999 > dumpFile.dump
※すでにcreatedbで作成したDBに突っ込むとする。
psql -d [作成されているDB] -f [dumpファイル]
ex) psql -d test -f dumpFile.dump -U postgres
ex)
| schema | Name | Object | Description(tableのComment) |
| public | table | table | testTableです |
こんな感じで表示される。
ex)
| Column | Type | Modifiers | Description(ColumnのComment) |
| admin_mail_history_id | bigint | not null | 管理者メール送信履歴のID |
| create_date | timestamp without time zone | 作成日 |
こんな感じで表示される。