「PostgreSQL 14」データベースを作成する
環境
Windows10 64bit
PostgreSQL 14.1
書式
CREATE DATABASE データベース名
使用例
1.データベースを作成します
postgres=# create database arkgamedb;
CREATE DATABASE
2.データベース一覧を表示します
postgres=# \l
データベース一覧
名前 | 所有者 | エンコーディング | 照合順序 | Ctype(変換演算子) | アクセス権限
-----------+----------+------------------+--------------------+--------------------+-----------------------
arkgamedb | postgres | UTF8 | Japanese_Japan.932 | Japanese_Japan.932 |
postgres | postgres | UTF8 | Japanese_Japan.932 | Japanese_Japan.932 |
template0 | postgres | UTF8 | Japanese_Japan.932 | Japanese_Japan.932 | =c/postgres +
| | | | | postgres=CTc/postgres
template1 | postgres | UTF8 | Japanese_Japan.932 | Japanese_Japan.932 | =c/postgres +
| | | | | postgres=CTc/postgres
(4 行)