Comment 3 for bug 817796

Revision history for this message
Hugh Davenport (hugh-davenport) wrote :

I don't think we can get any more optimized for MySQL.

MySQL doesn't have UPDATE FROM sql syntax (like what was done with the postgres optimization).

Another option would be to do an UPDATE and a SELECT query inside the SET clause, but from the page http://dev.mysql.com/doc/refman/5.6/en/update.html down the bottom we have the following:
"Currently, you cannot update a table and select from the same table in a subquery."

This basically means we can't update the group table without SELECTing the needed information before hand. Doing it this way makes a bulk UPDATE statement difficult. Because of this, I think we should just keep as is for mysql upgrades.

Thoughts?

Cheers,

Hugh