"BUG #18764: Delete conditions causing inconsistencies in Federated tables"
Removed logic in ha_federated::write_row, which checks field query ids in the loop which builds the query to run on the remote server. mysql-test/r/federated.result: "BUG #18764: Delete conditions causing inconsistencies in Federated tables" New test results for test that verifies that one can insert to rows using "insert into... select * from..", delete them by id, then immediately insert them in the same way they were originally inserted. mysql-test/t/federated.test: "BUG #18764: Delete conditions causing inconsistencies in Federated tables" New test that verifies that one can insert to rows using "insert into... select * from..", delete them by id, then immediately insert them in the same way they were originally inserted. sql/ha_federated.cc: "BUG #18764: Delete conditions causing inconsistencies in Federated tables" Removed the logic in ha_federated::write_row which checked the query id of each field and compared it to the thread query id. Each field has a query id, and the problem used to be that if I did an insert no fields specified, the field value would contain the last inserted value for that field. The way to work around this was to see if the query id for that field was the same as the current query id or of the rest of the field query ids. If it wasn't, that told me the query didn't have the field value specified. Somewhere from when I wrote that code to now the problem went away, and there was no longer the need for this logic. Also removed the bool "has_fields", which needs not exist and using table->s->fields is sufficient.
Showing
Please register or sign in to comment