Re: Is this a buggy behavior?

Поиск
Список
Период
Сортировка
От Erik Wienhold
Тема Re: Is this a buggy behavior?
Дата
Msg-id kcpy5gmmzl2y5mvagzcc4yz2xwhwltvgfeull2euqajmrcy4cv@ri2gs7yj5s4i
обсуждение исходный текст
Ответ на Re: Is this a buggy behavior?  (Thiemo Kellner <thiemo@gelassene-pferde.biz>)
Список pgsql-general
On 2024-03-24 16:28 +0100, Thiemo Kellner wrote:
> Am 24.03.2024 um 16:17 schrieb Tom Lane:
> 
> > To do that, we'd have to remember that you'd said NULL, which we
> > don't: the word is just discarded as a noise clause.  Considering
> > that this usage of NULL isn't even permitted by the SQL standard,
> > that seems like a bit too much work.
> 
> "Considering that this usage of NULL isn't even permitted by the SQL
> standard" is in my opinion a strange argument.

I don't know if the SQL standard ever allowed the NULL "constraint", but
the 2003 revision (the oldest one that I've got) does not allow it:

From Part 2, 11.4 <column definition>:

    <column constraint> ::=
        NOT NULL
      | <unique specification>
      | <references specification>
      | <check constraint definition>

Postgres only accepts it to be compatible with other RDBMS. [1]

[1] https://www.postgresql.org/docs/current/sql-createtable.html#SQL-CREATETABLE-PARMS-NULL

-- 
Erik



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

Предыдущее
От: Andreas Kretschmer
Дата:
Сообщение: Re: Is this a buggy behavior?
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: Is this a buggy behavior?