SELECT UNION truncate string fields at 510 character

Forum related to SQLite

Moderators: gto, cipto_kh, EgonHugeist

Post Reply
OsquiVilla
Fresh Boarder
Fresh Boarder
Posts: 6
Joined: 16.11.2017, 13:25

SELECT UNION truncate string fields at 510 character

Post by OsquiVilla »

Hello:

I have a SQLite database with 6 tables. When I use an SQL command with 6 SELECT and UNION, if the result responds only to one table, everything is correct, but if the result involves more than one table, the text fields are truncated to 510 characters.

Uso Delphi 2006, sqlite3 y ZeosLib 7.1.14

Please help :( :( :( :( :(
marsupilami
Platinum Boarder
Platinum Boarder
Posts: 1935
Joined: 17.01.2011, 14:17

Re: SELECT UNION truncate string fields at 510 character

Post by marsupilami »

Hello OsquiVilla,

duh - hmm - the best answer would be to use another database - Firebird for example ;) SQLite is a bit of a hard case since from a Zeos / Delphi point of view it doesn't have Varchar fields at all, only Memo fields... That said - Zeos tries to emulate Varchar fields by truncating SQLite Varchar fields.

Do you remember which SQL you used to create your tables? Could you provide a small example database and project? Did you try to use Zeos 7.2?

With best regards,

Jan
OsquiVilla
Fresh Boarder
Fresh Boarder
Posts: 6
Joined: 16.11.2017, 13:25

Re: SELECT UNION truncate string fields at 510 character

Post by OsquiVilla »

Yes, I have a piece of sql and code, but now I'm noy at home.

But, the truncated field are Memo, not Varchar.

I just download 7.2 and I'll try. Later I'll send the code and sql too.

Thanks
marsupilami
Platinum Boarder
Platinum Boarder
Posts: 1935
Joined: 17.01.2011, 14:17

Re: SELECT UNION truncate string fields at 510 character

Post by marsupilami »

Hello OsquiVilla,

are there any news on this?

With best regards,

Jan
OsquiVilla
Fresh Boarder
Fresh Boarder
Posts: 6
Joined: 16.11.2017, 13:25

Re: SELECT UNION truncate string fields at 510 character

Post by OsquiVilla »

Yes, I instaled the last 7.2 and the error disappear. But now, I need to change all .Open with .ExecSQL because an error occurs jaja. But this new version doesn´t truncate the strings.

Thanks for all
Post Reply