0

When I do \l I see myexampledb, then I do dropdb 'myexampledb' in the terminal, I got no error, I do \l again, the db isn't deleted, what's wrong?

I did this exactly:

  1. I do psql
  2. I got error of psql: FATAL: database "steven" does not exist
  3. I do psql -d postgres
  4. I do dropdb 'postgres'
  5. I do \ls
  6. the postgres db isn't removed
5
  • Please show us exactly where and how you ran those query. Commented Dec 13, 2018 at 14:59
  • @a_horse_with_no_name updated my question, I'm curious why do I have error in step 2 Commented Dec 13, 2018 at 15:03
  • you need to createdb steven first. Commented Dec 13, 2018 at 15:05
  • @a_horse_withi_no_name which command I need ;? I can't do dropdb 'postgres';`, I got syntax error. Commented Dec 13, 2018 at 15:06
  • any clue why I got postgres=# dropdb 'postgres'; ERROR: syntax error at or near "dropdb" LINE 1: dropdb 'postgres'; ^ postgres=# ?? Commented Dec 13, 2018 at 16:05

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.