Hi all,
> Yes, we'll have to document this clearly:
>
> - When used with CAST() they are evaluated each time the code is executed and
> return the current date (or, in the case of 'now', timestamp). In this case,
> they are more up-to-date than the CURRENT_ variables, which are
> evaluated once
Hi Lester,
> http://fbwiki.lsces.co.uk/wiki/index.php?page=NOW
> Hopefully this is the correct information ...
Correct but not entirely complete, with what we now know. You may want to add a
warning that when shorthand casts are used (or whatever you want to call them),
'NOW' and friends are ev
Mark Rotteveel wrote:
>> - When used as shorthand casts / datetime literals they are evaluated only
>> once: at parse/prepare time. In this case, they are often*less* up-to-date
>> than the CURRENT_ variables, because the latter are refreshed
>> every time a prepared query is executed again.
On 4-10-2011 17:27, Paul Vinkenoog wrote:
> Dmitry wrote:
>
>>> 'YESTERDAY', 'TODAY' and 'TOMORROW'
>>> These are not context variables, but serve the same purpose. See 'NOW',
>>> which is also documented under Context variables (quotes and all).
>>
>> They can behave as either literals substitute
Dmitry wrote:
> > 'YESTERDAY', 'TODAY' and 'TOMORROW'
> > These are not context variables, but serve the same purpose. See 'NOW',
> > which is also documented under Context variables (quotes and all).
>
> They can behave as either literals substituted immediately (timestamp
> 'today') or as conte
Paul Vinkenoog wrote:
> Will do some more testing tomorrow afternoon. Whatever the outcome, we'll
> have to adapt the documentation at this point.
http://fbwiki.lsces.co.uk/wiki/index.php?page=NOW
Hopefully this is the correct information ...
(Timestamps on files are new as I had to strip some ha
04.10.2011 2:19, Paul Vinkenoog wrote:
> However, I just had a surprise: within a PSQL module, "timestamp 'now'" and
> "date 'today'" stayed the same throughout the execution (I built in a delay
> loop and made sure the system day changed while the module ran).
>
> What's more: in a prepared sta
Thomas and all,
> I am also unsure about documenting 'TODAY''s usefulness for measuring time
> intervals in procedures, but I left it in anyway.
It doesn't really measure (clock) time intervals, but it should notice the
passing of a day.
However, I just had a surprise: within a PSQL module, "t