Markus Dorner could you provide all the mapping information for the both entities?
I confirm that Gunnar is right, there is already code to manage this and it seems to work in the test cases.
Thanks for the additional information!