# PostgreSQL *This page contains information about SQL syntax of the Postgres flavor. For general information, see [[Postgres]].* ### [`CREATE TABLE` ](https://www.postgresqltutorial.com/postgresql-tutorial/postgresql-create-table/) ```sql CREATE TABLE accounts ( user_id serial PRIMARY KEY, username VARCHAR ( 50 ) UNIQUE NOT NULL, password VARCHAR ( 50 ) NOT NULL, email VARCHAR ( 255 ) UNIQUE NOT NULL, created_on TIMESTAMP NOT NULL, last_login TIMESTAMP ); ``` ### [`DROP DATABASE`](https://www.postgresql.org/docs/current/sql-dropdatabase.html) Outside of the database that is to be dropped, e.g. the in `postgres` db: ```bash psql postgres ``` ```sql DROP DATABASE example; ``` It may fail if there are outstanding connections to the database.