Subject Re: [IBO] IB_Query x IBOQuery - Using fieldbyname
Author Helen Borrie
At 11:27 AM 17/05/2005 -0300, you wrote:
>IB-6, IBO 4.5ai (registered) - Delphi 7 Pro
>-----------------------------------------------------------
>Dear Friends
>
>I need to create and open a table, with IB_query, using this:
>..............
> tmpTabela := TIB_Query.Create(Application);
> with tmpTabela do
> begin
> DataBaseName := Salias;
> tmptabela.SQL.Text := 'SELECT SEMAPHOR.ch_sem,SEMAPHOR.nodulo
>from SEMAPHOR where CH_SEM = '+quotedStr(SCh_sem);
> tmpTabela.ExecSQL;
> end;
>
>When the SQL results in one or more fields, after posicioning in the
>first record, a command like: tmptabela.fieldbyname('ch_sem').AsString
>yelds empty. Why?
>
>When using IBOQuery the result on
>tmptabela.fieldbyname('ch_sem').AsString yelds the correct content.
>What I need to do to get the correct content of the field, using
>IB_Query?

Don't use DatabaseName for IB_Query, use the IB_Connection property. You
would be well-advised to avoid DatabaseName for IBOQuery as well, in
preference for IB_Connection.

Helen


>
>Thanks in advance.
>
>
>Hércules Russano
>HRsoft Informática
>0xx21-26013970 - 3246-2342
> <http://www.hrsoft.com.br/> www.hrsoft.com.br
>MSN Messenger: <mailto:hrsoftbrasil@...>
>hrsoftbrasil@...
>Skype: hrsoftbrasil
>
>
>
>
>
>[Non-text portions of this message have been removed]
>
>
>
>___________________________________________________________________________
>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 Info papers,
>keyword-searchable FAQ, community code contributions and more !
>Yahoo! Groups Links
>
>
>
>