Blob fields problem with Unicode Firebird

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
andy_bri
Posts: 19
Joined: Fri 02 Oct 2009 12:36

Blob fields problem with Unicode Firebird

Post by andy_bri » Wed 04 Sep 2019 09:45

I am using:
Firebird 2.5.8
Delphi 10.3.2
Unidac 8.0.1
Windows 10, but also WIndows 7

I connect to the database using SpecificOptions.UseUnicode set to True, Charset UTF8.
If I try to set values containing Ukrainian characters to VARCHAR field, it works ok.
But if I set value like 'стан добрий' to blob field (BLOB SUB_TYPE TEXT), charset UTF8, it is changed to characters like '????'
I do not know if it is connected to Delphi or Unidac version, but it was working ok for many years before upgrading my tools.

Am I doing something wrong? Maybe I missed some configuration in new Delphi compiler? Did something changed?
How to resolve it?

andy_bri
Posts: 19
Joined: Fri 02 Oct 2009 12:36

Re: Blob fields problem with Unicode Firebird

Post by andy_bri » Wed 04 Sep 2019 10:40

Resolved.

I had to set SpecificOptions.EnabledMemos=True in TUniConnection component.

(Why was it working ok without it?)

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

Re: Blob fields problem with Unicode Firebird

Post by ViktorV » Wed 04 Sep 2019 14:22

To solve the issue, you can set the TUniConnection.SpecificOptions.Values['InterBase.EnableMemos'] property to 'True'. For example:

Code: Select all

TUniConnection.SpecificOptions.Values['InterBase.EnableMemos'] := 'True';

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

Re: Blob fields problem with Unicode Firebird

Post by ViktorV » Mon 09 Sep 2019 13:10

andy_bri wrote: Wed 04 Sep 2019 10:40 Resolved.

I had to set SpecificOptions.EnabledMemos=True in TUniConnection component.

(Why was it working ok without it?)
In previous versions of UniDAC, the property defaulted to True, and the user wasn't able to change its value. The new version of UniDAC allows the user to change the value of the property that now defaults to False. To revert the behavior, you only need to set the property to True.

Post Reply