MySQL don't support conflict target on insert_all so we can't pass the
:unique_by option. But, if you don't check if the index exists MySQL will
successfully inset the data.
If there is a conflict in an index like the primary key the database will
raise an error. We should let the database decide if the data is acceptable
or not.
The test added on this commit exercise a table that has composite primary
keys, but, in order to keep all the Rails behavior working (given Rails
doesn't officially support composite primary keys) we set the primary
key to an auto increment :id column.