Names

Names in SQL are sequences of less than NAMEDATALEN alphanumeric characters, starting with an alphabetic character. By default, NAMEDATALEN is set to 32, but at the time the system is built, NAMEDATALEN can be changed by changing the #define in src/backend/include/postgres.h. Underscore ("_") is considered an alphabetic character.

In some contexts, names may contain other characters if surrounded by double quotes. For example, table or column names may contain otherwise disallowed characters such as spaces, ampersands, etc. using this technique.