I'm trying to change my backends to mysql.
I have the following routine
enter new person data, get the ID in main table, write that as foreign key in table 2, which should be straightforward. But I can't get this to work
where lkp is the lookup number. I also tried the version without '2&, same story.
it worked in before when i used access backend, but now it returns syntax error in insert into sentence, run time error 3134.
Maybe it has something to do with data types? mysql declares integer as 4 byte number, but nothing really changes when i define lkp as either integer or long.
Or as usually it might be a foolish syntax error
I have the following routine
enter new person data, get the ID in main table, write that as foreign key in table 2, which should be straightforward. But I can't get this to work
Code:
DoCmd.RunSQL "insert into table (tOrigo, tDel,t-bID) values ('" & Me.tTum & "','" & Me.tDel & "', '" & lkp & "')"
where lkp is the lookup number. I also tried the version without '2&, same story.
it worked in before when i used access backend, but now it returns syntax error in insert into sentence, run time error 3134.
Maybe it has something to do with data types? mysql declares integer as 4 byte number, but nothing really changes when i define lkp as either integer or long.
Or as usually it might be a foolish syntax error