Command line PostgreSQL - Switching Databases

When typing the solution:

psql -d bank_accounts
CREATE TABLE deposits (
id integer PRIMARY KEY,
name text,
amount float
I got this error:
ERROR: syntax error at or near “psql”

Even copying and pasting the answer. I can’t find the problem.

1 Like

Already solved. I was running psql before psql -d bank accounts.