Identifiers are used when referencing database objects.
Identifier rules attempt to follow Postgres semantics where possible.
Identifiers in a SQL query are case-insensitive.
All of the following queries behave exactly the same:
SELECT * FROM CITIES;
SELECT * FROM cities;
SELECT * FROM Cities;
Identifiers wrapped in a double quote ("
) retain their original casing.
Both of these queries are referencing different tables:
SELECT * FROM "Cities";
SELECT * FROM cities;
Case-insensitivity applies to all database objects, including functions.
Both queries are equivalent:
SELECT abs(-1.0);
SELECT ABS(-1.0);
When no explicit alias is provided for an expression in the SELECT
list, an
column name will be generated using the following rules:
?column?
is used.