Re: sqlca and spl
Posted in 1998
Thomas J. Girsch schrieb:
>
> Within SPL you can just do:
>
> LET nrow = DBINFO("sqlca.sqlerrd2");
>
> or
>
> LET lastser = DBINFO("sqlca.sqlerrd1");
>
> There's no need to do that SELECT.
In SPL it's the latter.
In versions without dbinfo-function you have to work with two
procedures: one sets a variable ("DEFINE GLOBAl ...") from inside a insert-trigger
and the other to read the "global" variable.
> Katrin Goericke wrote in message <36544CDE.2172@taz.de>...
[snip]
> > select unique dbinfo("sqlca.sqlerrd1") into mid
> > from "informix".systables;[snip]
Instead of unique you may select ... where tabid = 1;
If your database has no systables-entry with this tabid, you won't be
interested in serial-id's anymore;-))
hth
martin