Ok here is my situation....:
I have some data to insert in a MySQL DB that I got from a web based interface (upon the user pressing a "SUBMIT" button)
I want the data to be inserted in TABLE A and there exist corresponding data that I would (well...must be) inserted in TABLE B such that for each record in TABLE A there one (and only one) corresponding reccord in TABLE B
Given the fact that there are several persons connecting to the web interface and thus may make "submissions" for insertions in the DB how do U suggest I go about implementing this so as to ensure that the data gets inserted in TABLE A and the corresponding data gets inserted in TABLE B....?
My plan wuz to insert the data in TABLE A (which as an AUTO_INCREMENT column) then using LAST_INSERT_ID() acertain the AUTO_INCREMENT "id" from TABLE A and insert the correspondig data in TABLE B and "manually" (thus avoiding the use of an AUTO_INCREMENT column...which I would much prefer to use) give it the "ID" returned from LAST_INSERT_ID() thus ensuring that each record in TABLE A corespond to one and only one record in TABLE B...what do U think.......(all this came up before I started reading about TRANSACTION....nevertheless I feel more "compitent" with my "method")