Re: Function's LEAST, GREATEST and DECODE (Oracle vararg polymorphic functions)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Function's LEAST, GREATEST and DECODE (Oracle vararg polymorphic functions)
Дата
Msg-id 21609.1119580015@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Function's LEAST, GREATEST and DECODE (Oracle vararg polymorphic functions)  (Pavel Stehule <stehule@kix.fsv.cvut.cz>)
Ответы Re: Function's LEAST, GREATEST and DECODE (Oracle vararg  (Pavel Stehule <stehule@kix.fsv.cvut.cz>)
Список pgsql-patches
Pavel Stehule <stehule@kix.fsv.cvut.cz> writes:
+             /* If any argument is null, then result is null (for GREATEST and LEAST)*/

Are you sure about that?  The only reference I could find says that
these functions are not strict in Oracle:

http://download-east.oracle.com/otn_hosted_doc/rdb/pdf/sql_ref_v71_vol1.pdf
on page 2-185:

 The NULL keyword can appear in the list but is ignored. However, not all
 value expressions can be specified as NULL. That is, a non-NULL value
 expression must be in the list so that the data type for the expression
 can be determined.
 The GREATEST and LEAST functions can result in NULL only if at run time
 all value expressions result in NULL.

The strict interpretation is mathematically cleaner, no doubt, but
offhand it seems less useful.

            regards, tom lane

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

Предыдущее
От: Neil Conway
Дата:
Сообщение: Re: Another unused variable
Следующее
От: Tatsuo Ishii
Дата:
Сообщение: Re: EUC_JP and SJIS conversion improvement