Good news, everyone;
I've created a PHP script which exports an sql script or inserts history data into RadioDJ table. I need to polish it a bit and test, but for now it works for MySQL to MySQL history migration. I have to test if it works with Firebird.
Few fields are missing from resulting data - id_subcat (sub category reference), disk_no (no disc numbers in SAMDB), original_artist, copyright.
I'll report back here how it goes. If anyone is interested in my script in its current state, please ask here or PM me.