Hi All,
I am trying to get the LAST_INSERT_ID after an INSERT into a Mysql table.
I know this code is incorrect but I can't find the correct way of using it in B4j.
Thanks
Any help appreciated.
I am trying to get the LAST_INSERT_ID after an INSERT into a Mysql table.
B4X:
dim lastID as INT
gSQL.ExecNonQuery2("INSERT INTO table VALUES (?,?,?,?,?,?)",Array As Object(Null,u(1),u(2),u(3),u(4),Null))
lastID = gSQL.ExecQuery("LAST_INSERT_ID()")
Log("Last ID +"&lastID)
I know this code is incorrect but I can't find the correct way of using it in B4j.
Thanks
Any help appreciated.
Last edited: