Mysql – Merge table rows that are referenced as foreign keys in other tables
I have a table companies in which there are some duplicated rows I found with a simple GROUP BY name. This companies table has a PRIMARY KEY id which is referenced in several other tables, under the name company_id, which…