Subject | Re: [firebird-support] Re: current_timestamp behavior |
---|---|
Author | Teträm Corp |
Post date | 2009-02-08T09:23:24Z |
well it should be:
rdb$set_context('USER_TRANSACTION', 'start_time', cast(timestamp 'now'
as varchar(255)));
Thierry
Teträm Corp a écrit :
rdb$set_context('USER_TRANSACTION', 'start_time', cast(timestamp 'now'
as varchar(255)));
Thierry
Teträm Corp a écrit :
>
> Hi,
>
> if this variable does not exists, you can do this with a database trigger:
>
> CREATE trigger test active on transaction start position 0
> AS
> begin
> // I don't remember what should be the namespace parameter value
> rdb$set_context(..., 'start_time', cast(timestamp 'now' as varchar(255)));
> end
>
> and use rdb$get_context when you need this value
>
> Thierry
>
> woodsmailbox a écrit :
> >
> > > No, it returns the that was current at the start of a DML operation.
> > >
> > > Fidel.
> > >
> >
> > So I see.
> >
> > It's not the first time I got mislead by firebirdfaq.org (eg.
> > http://www.firebirdfaq.org/faq114/ <http://www.firebirdfaq.org/faq114/>
> > <http://www.firebirdfaq.org/faq114/
> <http://www.firebirdfaq.org/faq114/>>). I couldn't find nothing in the
> > ref. manuals or implementation notes about this so I'm not sure how it
> > should behave.
> >
> > Anyway, is there a way to get transaction start time? Thanx.
> >
> >
>
>