postgresql_16:7.2.2.5 Examples
PostgreSQL 16 > Reference > PostgreSQL Client Applications > createdb > Examples
To create the database demo using the default database server: $ createdb demo
To create the database demo using the server on host eden, port 5000, using the template0 template database, here is the command-line command and the underlying SQL command: $ createdb -p 5000 -h eden -T template0 -e demo CREATE DATABASE demo TEMPLATE template0;