Subject | RE: [IBO] [Jason] Fail to prepare sentence in all my queries after update to IBO 4.9.14 |
---|---|
Author | Support List |
Post date | 2011-09-14T18:05:38Z |
> Hi Jason, the happy guy :);-)
> Sorry by incovenience, but after update to a new version IBO 4.9.14, IThis should still work just fine. Perhaps you can send me a sample app
> need to know if you change some metohods, I explain :
>
> Before (IBO 4.6), I was create a query in this way :
>
> m:=TIB_Query.Create(Self);
> m.IB_Connection:=SetFB.IB_Connection;
> m.sql.clear;
> m.sql.add('DELETE FROM CLIENTS');
> m.sql.add('WHERE id_client='+IntToStr(nId)+';');
> ---> m.ExecSQL;
>
> But now, If try this query in IBO 4.9 I receive error message "fail to
> prepare a sentence".
showing me the problem? I'll also need to know what version of
InterBase/Firebird you are working with as well as what version of Delphi.
> Then I need to change to :Actually, if you are not going to have a statement prepared and then pass in
> ---> m.ExecuteDDL(m.sql.text);
> To run satisfatory.
parameter values, etc. for repeated executions, you should use this method
as it will have much faster performance.
> The same problem when I use MyIB_SQL.Execute to exec a SP like 'EXECUTEThis should also work just fine so I'll need to see a sample app showing me
> PROCEDURE BLABLA(...)', but now I need to change too.
the problem.
> I would like to know if is that right and I need to change my mind andI don't have enough information to tell if IBO has a bug in it or not. Also,
> change all my lines to adapter to this new method, or I doing wrong or
> it´s a IBO bug.
as I said above, there may be some significant performance improvements by
using the ExecuteDML() method. Only use the ExecuteDDL() method if you are
doing things like CREATE TABLE or ALTER TABLE, etc.
Hope this helps,
Jason LeRoy Wharton