MySQL Forums
Forum List  »  Triggers

Re: Autoincrement ID copied by trigger
Posted by: Dave Banthorpe
Date: March 31, 2015 02:38AM

ok this is getting weird! I even changed the column name of the id in the target table so something else (gpsid) and explictly told the trigger to use a null value for that field - which should force the InnoDB engine to use the local autoincrement value. BUT IT STILL COPIES THE SOURCE VALUE!


INSERT INTO mastergps.gps
(gpsid,tstamp, deviceid, lat, lng, speed, alt)

VALUES
(null,NEW.tstamp,NEW.radioid, NEW.lat, NEW.lng, NEW.speed, NEW.alt);

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: Autoincrement ID copied by trigger
1190
March 31, 2015 02:38AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.