Frage

I have a postgres database named aarons_db in ubuntu linux. I'm trying to delete a table called pnt within aarons_db. To do this, I am using the following command:

DROP TABLE pnt

Unfortunately, this does not appear to drop the table. My best guess is that there is some sort of admin privileges that I have not configured properly. The following shows the database, and commands used to try and drop the table.

What is preventing me from dropping the pnt table?

There is a similar question here, although the user is running into a cache error, which is not happening in my case.

enter image description here

War es hilfreich?

Lösung

Community Wiki answer, originally a comment on the question by a_horse_with_no_name

You need to end every SQL statement with ;. You didn't do that and thus your statement was not executed at all. Run DROP TABLE pnt; instead. See e.g. here: Understanding postgres prompts

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit dba.stackexchange
scroll top