Valid characters for user/role/group names?

Поиск
Список
Период
Сортировка
От Roderick A. Anderson
Тема Valid characters for user/role/group names?
Дата
Msg-id 49A576C7.3090909@cyber-office.net
обсуждение исходный текст
Ответы Re: Valid characters for user/role/group names?  (Sam Mason <sam@samason.me.uk>)
Tangent Ref: Valid characters for user/role/group names?  ("Roderick A. Anderson" <raanders@cyber-office.net>)
Список pgsql-general
In my continuing quest for multi-tenant ways I'm trying to come up with
a method to name roles, users, and groups that will not clash across the
cluster.  The plans are to have one database per tenant and place
applications in different schema in those databases.  This is working
fine so far but I'm now trying to come up with a naming scheme that will
allow a dba  account for tenant_1, tenant_2, etc.
    I found, several months ago, a posting about using the at "@" symbol
in a role name so there could be a dba@tenant_1, dba@tenant_2, etc.  I
can't find the article again but I remember there was a reference to
possible issues with using the '@' and username entries in pg_hba.conf
    If the '@' isn't a problem (other than possibly not being valid
according to the SQL standard I was going to use an '@tenant_1.txt'
entry in pg_hba.conf and place dba@tenant_1, bob@tenant_1,
sally@tenant_1 in it.

But according to

http://www.postgresql.org/docs/current/interactive/sql-syntax-lexical.html

"SQL identifiers and key words must begin with a letter (a-z, but also
letters with diacritical marks and non-Latin letters) or an underscore
(_). Subsequent characters in an identifier or key word can be letters,
underscores, digits (0-9), or dollar signs ($). Note that dollar signs
are not allowed in identifiers according to the letter of the SQL
standard, so their use might render applications less portable. ... "

I'm wondering what the reference to "non-Latin" letters means.

Anyone have a solution to this?


Thanks,
Rod
--


В списке pgsql-general по дате отправления:

Предыдущее
От: Thom Brown
Дата:
Сообщение: Re: Warm standby failover mechanism
Следующее
От: Sam Mason
Дата:
Сообщение: Re: Valid characters for user/role/group names?