Reputation: 93
I connect to the remote ubuntu 20.04 computer from the terminal with ssh, connect to the database that I have installed on the postgres user, and I want to see the data in a column with psql commands. I am not displaying the data, but the columns as much as the number of data.
The codes I write:
SELECT 'Name' FROM "Restaurants";
The result:
How can I view the datas?
Upvotes: 0
Views: 61
Reputation:
'Name'
is a string constant, identifiers (column names) must be enclosed in double quotes (the same you did with the table name)
SELECT "Name" FROM "Restaurants";
Upvotes: 2