ehr...

Den 23-01-2011 15:36, Carsten Pedersen skrev:
Seeing from later posts that you're using InnoDB, why don't you simply
wrap the INSERT/UPDATE into a transaction? You don't avoid the UPDATE,
but I'm not sure I understand the need to mess w/ triggers.

BEGIN
INSERT INTO t(id) NULL
UPDATE t SET xxx=last_insert_id()

UPDATE t SET xxx=i WHERE i=last_insert_id()

obviously.

Sorry.

Best,

/ Carsten



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/mysql?unsub=arch...@jab.org

Reply via email to