Delphi/MyQL EAccessViolation exception on INSERT/UPDATE
Posted on 2005-04-15
I'm accessing a local MySQL db with a TADOQuery connected via a TADOConnection
some of my code:
sql := 'insert onto car set reg_plate="123-456x", make="merc", model="kompressor";';
query is my TADOQuery object, connected to the DB via TADOConnection.
On Run, SELECT works fine, & DELETE but, Insert/update result in this error message:
"project ciimsfp.exe raised exception class EAccessViolation with message 'Access violation at address 1F453E7E in module 'msado15.dll'. Write of address 00BFA004'. Process stopped..."
then fails to insert into DB. The same code actually inserts if I use query.open() instead of query.ExecSQL() although it raises an error that SQL does not return a result.
NB: the SQL is valid for my DB! I'm using MyODBC 3.51 & its BDE config seems OK.
How do insert/update into the DB without raising an exception?