bug? incorrect return type from extract

Поиск
Список
Период
Сортировка
Искать

bug? incorrect return type from extract

От:
Pavel Stehule <stehule@kix.fsv.cvut.cz>
Дата:
Hello

Is correct so extract(day from current_date) return double? I need 
explicit cast for this expression

current_date - extract(day from current_date) + 1 -- don't work

ERROR:  operator does not exist: date - double precision
HINT:  No operator matches the given name and argument type(s). You may 
need to add explicit typecasts.

why? I have cvs PostgreSQL updated 23.7.

regards,
Pavel Stehule

Re: bug? incorrect return type from extract

От:
Tom Lane <tgl@sss.pgh.pa.us>
Дата:
Pavel Stehule  writes:
> Is correct so extract(day from current_date) return double?

extract(anything) returns double.

			regards, tom lane
FAQ