This question already has an answer here:
I have 2 vector line layers. They are subjacent, so one of them is exactly on top of the other but the features have different nodes and attributes.
My goal is to create labels and descriptions for the features which contain attributes from both. The idea is to create a third layer which is split up like the two existing ones and has the attributes from both.
So I want to merge both layers and the result layer should have all the nodes and all attributes.