Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
WF Software — — source: Informix-list mailing list archive (1991-1998)
In article <35A9E5C5.8DD6580E@procent.hu>, wolf.p@procent.hu (Wolf Peter)
wrote:
> HOW can I GET the real current time in stored procedure call?
>
> These test program proofs that the built-in current function in a stored
> procedure the procedure returns the time when the procedure BEGAN not
> the CURRENT time!
>
>
> create procedure test() returning datetime year to second;>
> define i int;
>
> for i= 1 to 5
> return current do with resume;
> system( 'sleep 3' );
> end for;
>
> end procedure;
>
> The execute procedure test()
> returns
> 1998-07-13 11:33:53
> 1998-07-13 11:33:53
> 1998-07-13 11:33:53
> 1998-07-13 11:33:53
> 1998-07-13 11:33:53
>
>
>
Sorry this is a feature, CURRENT is set when the first SPL is run and
AFAIK all subsequent SPL calls from within the initial SPL will inherit
this value. If you really need the value you can drop to the OS but I've
found this gives a typical overhead of about 0.5s per call, which can be
significant depending on your system.
Paul Watson
WF Software Ltd.
Tel. (+44) 1436 674729
Fax. (+44) 1436 678693
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.