ss - oscar

My SQL Dump

MySQL musings by a self professed MySQL Geek

  • 1

Tell them to fix it ...

Did you file a bug report for this?



I'll look at adding this to 5.0.


you know it makes me hot when you get all techie-babble...

I'm surprised that whether or not it logs to the binary log is dependent on the storage engine. I guess it's because nothing's technically inserted, and writing happens after an insert?

The write to the binary log happens after write_record() is called to insert the data into the table. The binary log write checks the value of thd->insert_id_used to determine if it needs to write an INSERT_ID_EVENT into the binary log.

The underlying ha_blackhole::write_row was not calling update_auto_increment(), which is inherited and sets thd->insert_id_used among a few other things. As thd->insert_id_used was not getting set to TRUE the binary log writer omitted "the environment" for the INSERT, which in this case is the SET INSERT_ID statement.

well done

thats for sure, dude

  • 1

Log in