Subject | [IBO] Problem with TIBOQuery |
---|---|
Author | Helton de Oliveira |
Post date | 2001-12-20T12:33:14Z |
Hi Helen,
Thanks for your help.
I made the changes, except the "Dataset.ParamByName" because of a
"Undeclared identifier: 'ParamByName" error, and i'm still getting an empty
dataset.
If i right click the TIBOQuery and enter in the Edit mode, i can prepare,
set the param to 12 and open the DataSet, and it works fine.
it seems to me that it is not passing the parameter at run-time and get no
data since there isn't "MES=0" in the table.
This same problem is hapening with other TIBOQuery linked to another
table.
Other TIBOQueries without paremeters works fine. Could be a conection
problem ? I'm using TIBODatabase.
Helton
Thanks for your help.
I made the changes, except the "Dataset.ParamByName" because of a
"Undeclared identifier: 'ParamByName" error, and i'm still getting an empty
dataset.
If i right click the TIBOQuery and enter in the Edit mode, i can prepare,
set the param to 12 and open the DataSet, and it works fine.
it seems to me that it is not passing the parameter at run-time and get no
data since there isn't "MES=0" in the table.
This same problem is hapening with other TIBOQuery linked to another
table.
Other TIBOQueries without paremeters works fine. Could be a conection
problem ? I'm using TIBODatabase.
Helton
> ----- Original Message -----"MES".
> From: "Helen Borrie" <helebor@...>
> To: <IBObjects@yahoogroups.com>
> Sent: Quinta-feira, 20 de Dezembro de 2001 09:11
> Subject: Re: [IBO] Problem with TIBOQuery
>
>
> > At 08:57 AM 20-12-01 -0200, Helton de Oliveira wrote:
> > >Hi,
> > >
> > >I'm porting a BDE application to IBO using the TIBO components and i'm
> > >having problems with a TIBOQuery with a SmallInt parameter called
> > >conforms
> > >The TIBOQuery didn't find any data. It seems not respect the parameter
> since
> > >there is data in the table especified on the Select clause which
> > >with "MES=12".___________________________________________________________________________
> > >
> > >Here is the select clause: "SELECT * FROM VctosDescs WHERE Mes = :Mes
> ORDER
> > >BY Mes, CodVctoDesc"
> >
> > Change this to omit Mes from the order by criteria - it's not logical to
> order a set by a column that cannot possibly have more than one value.
> >
> >
> > >Here is the BeforeOpen event of the TIBOQuery:
> > >
> > >procedure TdtmTables.qryVctDscBeforeOpen(DataSet: TDataSet);
> > >begin
> > > file://qryVctDsc.ParamByName('Mes').AsInteger := 12;
> >
> > Dataset.ParamByName....
> >
> > >end;
> > >
> > >Here is the AfterOpen event of the TIBOQuery:
> > >
> > >procedure TdtmTables.qryVctDscAfterOpen(DataSet: TDataSet);
> > >begin
> >
> > with Dataset do begin
> >
> > > file://if (qryVctDsc.BOF and qryVctDsc.EOF) then DoSomething;
> > > file://qryVctDsc.First;
> >
> > if IsEmpty then
> > DoSomething
> > ELSE
> > First;
> > end;
> >
> > Just make these changes and check whether you are still getting an empty
> dataset.
> >
> > Helen
> >
> >
> >
> >
> >
>
> > IB Objects - direct, complete, custom connectivity to Firebird or___________________________________________________________________________
> InterBase
> > without the need for BDE, ODBC or any other layer.
> >
>
> > http://www.ibobjects.com - your IBO community resource for Tech Infohttp://docs.yahoo.com/info/terms/
> papers,
> > keyword-searchable FAQ, community code contributions and more !
> >
> > Your use of Yahoo! Groups is subject to
> >
> >
> >
>