Restoring merged sources

In case it helps in some way, earlier this year @kku published the “Import CSV sources” tool among the Isotammi addons. See discussion here.

I’m happy to help you create SQL queries.