0

In T-SQL one can run both of these queries

SELECT Id FROM Nodes.Main

SELECT [Id] FROM Nodes.Main

How can I do something similar in PostgreSQL?

Slime recipe
  • 2,144
  • 2
  • 29
  • 49
  • Postgres complies with the SQL standard for quoting identifiers: http://www.postgresql.org/docs/current/static/sql-syntax-lexical.html#SQL-SYNTAX-IDENTIFIERS Note that in Postgres (and standard SQL) `"Id"` and `Id` are two different identifiers. – a_horse_with_no_name Sep 20 '15 at 13:55
  • Yeah, it is exactly what I was having hard time with. the fact that it changed the names I specified in the create table made it even more confusing. I guess I'll have some learning curve here.... – Slime recipe Sep 20 '15 at 14:01
  • As a general rule of thumb: never quote identifiers – a_horse_with_no_name Sep 20 '15 at 14:05

0 Answers0