Questions on IBDAC 8.0.1 and Firebird 4.0

Discussion of open issues, suggestions and bugs regarding IBDAC (InterBase Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
tsteinmaurer
Posts: 52
Joined: Thu 17 Dec 2009 08:25

Questions on IBDAC 8.0.1 and Firebird 4.0

Post by tsteinmaurer » Thu 16 Sep 2021 18:13

Hello,

just recently upgraded to IBDAC 8.0.1 (Delphi 32-bit), trying to use it with Firebird 4.0.

I have two issues/questions:

1)
When trying to connect to a Firebird 4.0 database, I get the following error message.

Code: Select all

Error loading plugin ChaCha
Module C:\Firebird\Firebird_400_5050_x86\plugins/ChaCha
exists but can not be loaded
The specified procedure could not be found.
After explicitly disabling WireCrypt in firebird.conf with

Code: Select all

WireCrypt = Disabled
and restarting the Firebird Server, I can connect. Is there something special needed in IBDAC so that I can connect to a database of a default Firebird Server installation? I can connect to the database with isql without issues.

2)
Querying MON$ tables, which now use the new TIMESTAMP WITH TIMEZONE for various fields, fails with a conversion error when using .AsDateTime as field access in my legacy application re-compiled with IBDAC 8.0.1.

Thanks for your help.

tsteinmaurer
Posts: 52
Joined: Thu 17 Dec 2009 08:25

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by tsteinmaurer » Thu 16 Sep 2021 19:30

ad 2)

I see a TIMESTAMP WITH TIME ZONE field maps to a TStringField in Delphi, which then obviously will fail with .AsDateTime.

Does IBDAC 8.0.1 support the new Firebird 4 isc_dpb_set_bind DPB somehow? If not, I think this should be a must have to ease running legacy applications with new data types, especially also with MON$ tables, as you don't control what data types are used there.

See also:
- https://www.firebirdsql.org/file/docume ... l-set-bind
- How Jaybird is dealing with that: https://firebirdsql.github.io/jaybird-m ... tatypebind

Thanks

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by ViktorV » Wed 22 Sep 2021 16:41

Hi!

Thank you for your inquiry!
1) This error means that the client library cannot load the required ChaCha plugin. Please try to specify the full path to the client library file in the CliebtLibrary field, so that the Plugins folder with the plugin file was also present there. Pay attention, all these files must have a bitness equal to the bitness of your application.
If this does not help in solving the issue, please send us your sample with the necessary files. And the firebird.conf file from your server.
2) In IBDAC 8.0.1 for Firebird 4, we supported INT128, DECFLOAT and large NUMERIC types, as well as table names up to 64 characters.
The TIMESTAMP WITH TIME ZONE type is supported as a string in this release.
Full support of this type will be added to the next release of IBDAC!
We will consider the possibility of supporting isc_dpb_set_bind DPB.
Should you have any questions, do not hesitate to ask!

Best regards,
Viktor

tsteinmaurer
Posts: 52
Joined: Thu 17 Dec 2009 08:25

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by tsteinmaurer » Fri 24 Sep 2021 05:00

Hello Viktor,

thanks for your reply!

ad 1): Likely this should be easy reproducible on your side.
- I simply extracted a Firebird 4.0.1 32-bit (matching my client app bitness) ZIP distribution into a folder
- The only thing I changed in firebird.conf is listening on port 5050
- In Delphi XE7, at design-time with TIBCConnection, trying to connect to my database with the following connect string "Data Source=localhost;Database=tourism.fdb;Port=5050;User ID=tourism;Password=xxx;Client Library=C:\Firebird\Firebird_400_5050_x86\fbclient.dll;Login Prompt=False" thus full qualified path to the client library of the extracted ZIP distribution

I still get a "Error loading plugin ChaCha ..."

ad 2): With full support you mean being able to access that sort of new date/time data type via .AsDateTime? From a backwards compatibility mode, the isc_dpb_set_bind DPB would be definitely useful as well.

Any timeline for the next release?

Thanks a lot,
Thomas

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by ViktorV » Fri 01 Oct 2021 15:57

Hi!

Unfortunately, we were unable to reproduce the behavior you indicated in our environment based on the data you provided - we connected to the server without any issues.
Therefore, please compose us a complete sample demonstrating the behavior you specified and send us all the server files and specify how you run it, like a server or a regular file.

Thanks in advance,
Viktor

tsteinmaurer
Posts: 52
Joined: Thu 17 Dec 2009 08:25

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by tsteinmaurer » Sun 17 Oct 2021 09:15

Hello Viktor,

did some additional digging. The ChaCha connectivity issue with Firebird 4.0 seems to be only the case, if the process in question also has another (older) fbclient.dll library loaded.

E.g. my Delphi XE7 IDE also automatically loads the fbclient.dll library from the Windows system directory, which is from Firebird 2.5. When I now try at design-time to connect to Firebird 4, although my IBDAC connection component has set the client library path to a Firebird 4.0 fbclient.dll, I get the ChaCha error message.

Additionally, in my application, although running out-side the Delphi IDE shows the same issue, cause my application ships and uses Firebird 2.5 embedded, thus my application / executable has the 2.5 embedded library loaded. When I now try to connect via my application to a Firebird 4 server / database, although the IBDAC connection component instance is using a proper path to a 32-bit Firebird 4 client library, I get the same ChaCha connectivity error.

Does this make sense? Any further ideas?

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by ViktorV » Thu 21 Oct 2021 15:17

Kindly note that you are going to always get this error message while using the Firebird 2.5 library because it doesn't support the required functionality.
Please specify the exact client library your application is using while receiving the error.
To retrieve the name and the path to the library loaded automatically, you can use a third-party utility, e.g. Process Explorer. In case it is not the Firebird 4 library please feel free to provide us with it.

tsteinmaurer
Posts: 52
Joined: Thu 17 Dec 2009 08:25

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by tsteinmaurer » Fri 22 Oct 2021 04:34

Viktor,

this is exactly the problem. My application uses Firebird 2.5 Embedded to connect to a 2.5 database which ships with my product. My customer then can connect via my application to various Firebird servers and databases, but as the Firebird embedded library of 2.5 is loaded first (otherwise my application won't start), a connection to Firebird 4.0 will fail, although the client library for the 4.0 connection was set using a 4.0 client.

I guess there is no way to mitigate that?

Regards,
Thomas

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by ViktorV » Tue 26 Oct 2021 14:42

Kindly note that the solution of this issue depends on the architecture of your application. For example, you can use one instance of TIBCConnection to connect to your Firebird 2.5 Embedded and another to connect with other servers. Or you can connect from your Firebird 2.5 Embedded and then change the Client Library property at runtime.

tsteinmaurer
Posts: 52
Joined: Thu 17 Dec 2009 08:25

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by tsteinmaurer » Tue 26 Oct 2021 14:52

Hello Viktor,

I'm already doing that. A dedicated TIBCConnection for my permanent connection to my Firebird 2.5 embedded database and then per connection to the customer database a separate/dedicated TIBCConnection with proper set client library.

Simply seems, as the connection to my 2.5 embedded database is the first connection, thus loading the 2.5 embedded library in the process memory, that a customer 4.0 connection then fails, although a 4.0 client library was provided.

Thomas

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by ViktorV » Fri 29 Oct 2021 16:03

Hey Thomas!

Thanks for the reply!

In order to give you a complete and accurate answer, please compose and send us a small sample demonstrating the behavior you indicated, with all the required files using our contact form:
https://devart.com/company/contactform.html

Looking forward to hearing from you!

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by ViktorV » Mon 08 Nov 2021 10:21

Kindly be informed that we were unable to reproduce the behavior you have indicated based on your data.
Please provide us a complete example demonstrating the behavior you specified, the client libraries you are using via our contact form:
https://devart.com/company/contactform.html

upscene
Posts: 306
Joined: Thu 19 Oct 2006 08:13

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by upscene » Fri 10 Dec 2021 09:47

ViktorV wrote: Wed 22 Sep 2021 16:41 2) In IBDAC 8.0.1 for Firebird 4, we supported INT128, DECFLOAT and large NUMERIC types, as well as table names up to 64 characters.
The TIMESTAMP WITH TIME ZONE type is supported as a string in this release.
Full support of this type will be added to the next release of IBDAC!
We will consider the possibility of supporting isc_dpb_set_bind DPB.
Should you have any questions, do not hesitate to ask!

Best regards,
Viktor
Hi Viktor,

The current implementation of WITH TIME ZONE is lacking, but you know that ;)

Will you use TSQLTimeStampOffsetField for this type?

I just tried mapping TIMESTAMP WITH TIME ZONE to TSQLTimeStampField, but that fails as well. It seems you cannot map (yet?) to TSQLTimeStampOffsetField?
Field: MON$CREATION_DATE
31-MAY-2021 7:44:20.0510 GMT
Will there be an option for a connection to map any TIME/DATE/TIMESTAMP field to TSQLTimeStamp(Offset)? Or do you have to use the data type mapping for that?

With regards,

Martijn

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by ViktorV » Fri 10 Dec 2021 12:45

Hi Martijn!

Thank you for contacting Devart and for your inquiry!

Kindly note that In UniDAC 9.1.1 the TIMESTAMP WITH TIME ZONE type is supported only as a string. Moreover, we return the string in the format that the server will pass it to us.

We will do our best to add full support for TIMESTAMP WITH TIME ZONE type in the new release and set it to the highest priority.
As soon as we add this support, we will immediately inform you so that you can check it on your side before the official version with this support is released.

Should you have any questions, do not hesitate to ask!

tsteinmaurer
Posts: 52
Joined: Thu 17 Dec 2009 08:25

Re: Questions on IBDAC 8.0.1 and Firebird 4.0

Post by tsteinmaurer » Mon 13 Dec 2021 15:11

Viktor,

I see IBDAC 8.0.2 was released.
2) In IBDAC 8.0.1 for Firebird 4, we supported INT128, DECFLOAT and large NUMERIC types, as well as table names up to 64 characters.
The TIMESTAMP WITH TIME ZONE type is supported as a string in this release.
Full support of this type will be added to the next release of IBDAC!
We will consider the possibility of supporting isc_dpb_set_bind DPB.
Should you have any questions, do not hesitate to ask!
What is the status in 8.0.2 in this regard?

Thanks,
Thomas

Post Reply