Subject Re: [IBO] mystery with ParamByName
Author Gediminas
--- In IBObjects@yahoogroups.com, "Gediminas" <gugini@f...> wrote:
> --- In IBObjects@yahoogroups.com, Helen Borrie <helebor@t...> wrote:
> > >CREATE PROCEDURE TU(TUID DECIMAL (15, 0))
> > >RETURNS ( SOID DECIMAL (15, 0),NAME VARCHAR (33))
> > >AS
> > >BEGIN
> > > for select
> > > s."SoID",
> > > s."Name"
> > > from TUR t
> > > join PRO p
> > > on t."ProID" = p."ProID"
> > > join AM_KL ak
> > > on p."AKID" = ak."AKID"
> > > join KLA k
> > > on ak."KlaID" = k."KlaID"
> > > join KL_SO ks
> > > on k."KlaID" = ks."KlaID"
> > > join SO s
> > > on ks."SoID" = s."SoID"
> > > where t."TuID" = :TuID and not exists ( select 1 from
TU_SO
> > >where "TuID" = :TuID and "SoID" = s."SoID" )
> > > into :SoID, :Name
> > > do
> > > SUSPEND;
> > >end
> >
> > OK, there are two problems with this procedure. 1) it needs to
have
> TUID
> > in its output set

Helen, added TuID to output set, but still can't assing SoID argument
with the ParamByName - field not found. TuID field as argument is
found.

Am I right, that IBO SP argument (AFields) list is independent from
the output set (Fields) list? when argument list is created, destroyed
and cleared?