Problem with delphi 7, zeos 6.6.6 stable & Firbird 2.5 f

Forum related to Firebird

Moderators: gto, cipto_kh, EgonHugeist

Post Reply
m-gun
Fresh Boarder
Fresh Boarder
Posts: 1
Joined: 03.11.2010, 02:12
Contact:

Problem with delphi 7, zeos 6.6.6 stable & Firbird 2.5 f

Post by m-gun »

I have a problem with Delphi 7 and Firebird zeos final version 2.5 dated 4 October, when it will connect and open a table using ZQuery1 an error like the following picture:

Image

Previously, I have long been using Zeos and firebird version I use 2.5 RC3. seek clarification from you all. Thanks
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

Try using the most recent zeoslib 7 snapshots. There protocol FB 2.5 should be available.

http://zeosdownloads.firmos.at/downloads/snapshots/

Mark
Image
jk
Fresh Boarder
Fresh Boarder
Posts: 7
Joined: 27.11.2008, 09:02

Post by jk »

is it possible fix this in 6.6.6?
i found that this bug reproduced only when using fbclient.dll v2.5
when i replaced to fbclient.dll v2.1 - (but server still stays 2.5) - all work fine

some code to reproduce:
zconnection1.protocol := 'firebird-2.1';
zconnection1.databasename := 'server:c\db.gdb';
zconnection1.connect;
zquery.sql.text := 'select * from table';
zquery.open;
zquery.sql.text := 'select * from anothertable'; // <--- AV

bug actually is very strange - looks like isc_dsql_free_statement in fbclient.dll v2.5 corrupting memory in some cases, if i change code to:

zquery.sql.text := 'select * from table';
zquery.open;
zquery.close; //<- change
zquery.sql.text := 'select * from anothertable'; // <--- no AV!

than all work fine.

after some debugging i found that:

destructor TZGenericCachedResolver.Destroy;
begin
FMetadata := nil; //<-- here calling isc_dsql_free_statement
FDatabaseMetadata := nil; //<-- here AV

after calling isc_dsql_free_statement object TZGenericCachedResolver - corrupted: Self variable - Innaccesible value, reading any property - AV, but before first line all was fine.
User avatar
Pitfiend
Senior Boarder
Senior Boarder
Posts: 68
Joined: 12.12.2009, 07:27

Post by Pitfiend »

Even in BDE you need to close a query before you assign a new sql sequence. IMHO you are asking for a feature no one will implement.
jk
Fresh Boarder
Fresh Boarder
Posts: 7
Joined: 27.11.2008, 09:02

Post by jk »

Pitfiend, you are mistaken, in BDE(and in ZEOS) there is no need to close query before assigning new sql - query will be closed automatically.
Post Reply