On Wed, 2 Jan 2019, Tom Lane wrote:
'today' is special as a date input string, so you can use it as a literal:
regression=# select 'today'::date;
date
2019-01-02
(1 row)
But it's not a SQL keyword, nor a function name, so you can't write it
without quotes.
Tom,
Now I under
Rich Shepard writes:
>Reading the manual I saw that 'today' is a special value, but it did not
> work when I used it as a column default; e.g.,
> start_date date DEFAULT today,
>Appending parentheses also failed. But, changing today to CURRENT_DATE
> worked. I've not found an explanation a
Reading the manual I saw that 'today' is a special value, but it did not
work when I used it as a column default; e.g.,
start_date date DEFAULT today,
Appending parentheses also failed. But, changing today to CURRENT_DATE
worked. I've not found an explanation and would appreciate learning why