public inbox for [email protected]
help / color / mirror / Atom feedFrom: Thom Brown <[email protected]>
To: [email protected]
To: [email protected]
Subject: Re: Reserved word: OWNER
Date: Fri, 13 May 2022 13:53:05 +0100
Message-ID: <CAA-aLv4EJmU2OCPugoknebZDUMXr=cX+tDkKt6Lp47h-kw_1TA@mail.gmail.com> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
On Fri, 13 May 2022 at 13:23, PG Doc comments form
<[email protected]> wrote:
>
> The following documentation comment has been logged on the website:
>
> Page: https://www.postgresql.org/docs/14/sql-keywords-appendix.html
> Description:
>
> You say it's a non-reserved word, but on this page:
> https://www.postgresql.org/docs/current/sql-alterdatabase.html#:~:text=To%20alter%20the%20owner%2C%2....
>
> you clearly use OWNER as a reserved word:
>
> ALTER DATABASE name OWNER TO { new_owner | CURRENT_ROLE | CURRENT_USER |
> SESSION_USER }
>
> and if I try to use OWNER as a column name in pgAdmin, it is marked blue (ie
> a reserved word). So which is it?
That sounds like a PgAdmin issue, and probably because of the way that
their syntactic highlighting works. OWNER isn't a reserved word.
postgres=# CREATE TABLE owner (owner TEXT);
CREATE TABLE
postgres=# \d owner
Table "public.owner"
Column | Type | Collation | Nullable | Default
--------+------+-----------+----------+---------
owner | text | | |
Regards
Thom
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: Reserved word: OWNER
In-Reply-To: <CAA-aLv4EJmU2OCPugoknebZDUMXr=cX+tDkKt6Lp47h-kw_1TA@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox