Widememo in dbEdit Delphi XE2, SQLite3

The alpha/beta tester's forum for ZeosLib 7.0.x series

Report problems concerning our Delphi 2009+ version and new Zeoslib 7.0 features here.

This is a forum that will be removed once the 7.X version goes into stable!!

Moderators: gto, EgonHugeist, olehs

Locked
PetrHL
Fresh Boarder
Fresh Boarder
Posts: 6
Joined: 21.09.2012, 12:28

Widememo in dbEdit Delphi XE2, SQLite3

Post by PetrHL »

Hello,

I just downloaded from SVN (trunk) and installed zeos db components to Deplhi XE2. It works but all fields defined as TEXT in sqlite database has in dbeEdit fields "widememo" text and not the correct value. Anyone knows what could be wrong, please?

Thank you!

Petr
User avatar
EgonHugeist
Zeos Project Manager
Zeos Project Manager
Posts: 1936
Joined: 31.03.2011, 22:38

Post by EgonHugeist »

PetrHL,

that's why TEXT means unlimited size. We can't determine a FieldBufferSize for TEXT in this case. So we load TEST as StringStream. This is a proplem of the lazy SQLite affinity:
http://www.sqlite.org/datatype3.html

The DataSets of Delphi/FPC need a fixed Buffersize for StringFields. But which size is correct for TEXT?

Simply declare the stringfields a VARCHAR(100) and you will have TWideString Fields instead... Just have a look to this link.
Best regards, Michael

You want to help? http://zeoslib.sourceforge.net/viewtopic.php?f=4&t=3671
You found a (possible) bug? Use the new bugtracker dude! http://sourceforge.net/p/zeoslib/tickets/

Image
miab3
Zeos Test Team
Zeos Test Team
Posts: 1310
Joined: 11.05.2012, 12:32
Location: Poland

Post by miab3 »

EgonHugeist,

I wonder if it would be a big problem to add in Properties for SQLite something like that?
TextAsVarchar = 20

And it only readonly mode (not to lose data).

Michal
User avatar
EgonHugeist
Zeos Project Manager
Zeos Project Manager
Posts: 1936
Joined: 31.03.2011, 22:38

Post by EgonHugeist »

miab3,

hm nope, that's a small patch. It would only work in the TZConnection.Properties. But how do you want to mange WANTED TEXT(memo) fields if such an option is available?
Best regards, Michael

You want to help? http://zeoslib.sourceforge.net/viewtopic.php?f=4&t=3671
You found a (possible) bug? Use the new bugtracker dude! http://sourceforge.net/p/zeoslib/tickets/

Image
Locked