sqlite, params, insert not working

The forum for ZeosLib 7.2 Report problems. Ask for help, post proposals for the new version and Zeoslib 7.2 features here. This is a forum that will be edited once the 7.2.x version goes into RC/stable!!

My personal intention for 7.2 is to speed up the internals as optimal a possible for all IDE's. Hope you can help?! Have fun with testing 7.2
Post Reply
vbazovic
Fresh Boarder
Fresh Boarder
Posts: 2
Joined: 16.04.2014, 12:43

sqlite, params, insert not working

Post by vbazovic »

Enviroment: CodeTyphon 4.9 with Zeos Rev 3112, ver 7.2.0 has a problem (works fine with 7.1.2) with sqlite3 (3.7.16.1 library version) on Linux.

When you try an insert/update query with parameters (ParamByName method) it does not work. This is some debug info:

Exception class: EZSQLException
Message: SQL Error: constraint failed
$0000000000A24A13 line 248 of source/dbc/ZDbcSqLiteUtils.pas
$0000000000A22CDA line 348 of source/dbc/ZDbcSqLiteStatement.pas
$0000000000905463 line 1960 of source/component/ZAbstractRODataset.pas
$0000000000507E09 line 765 of main.pas
$0000000000507938 line 856 of main.pas
$0000000000507258 line 330 of main.pas
$000000000050C79E line 1041 of main.pas
$00000000004F3415
$00000000004F14B5
$00000000004F91CE
$0000000000502A94
$00000000004C5D92 line 18 of ekartonsek.lpr

The only constraint is primary key.

When I drop this constraint I get correct number of rows with all nulls!!! SQL was insert into table with retruning statement (used Open method ).
PK is varchar.

I did try to fix it myself but without success.
User avatar
EgonHugeist
Zeos Project Manager
Zeos Project Manager
Posts: 1936
Joined: 31.03.2011, 22:38

Re: sqlite, params, insert not working

Post by EgonHugeist »

Could you attach a simple demo, please? just a console app would be sufficient..
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
Post Reply