- Source Schema
- Destination Schema
- Map
- XML Result
<ns0:Root xmlns:ns0="http://MappingError.DestinationSchema" />
<element1>
<field11>element1_0</field11>
<field12>element2_0</field12>
</element1>
<element2 fixedattribute="FixedValue"/>
<element3>
<field31>element3_0</field31>
</element3>
</ns0:root>
One solution is set for this element, an constant input value false, but my problem was that I had a lot elements with fixed attributes that mustn't be generated.
A solution for this is edit the map with notepad (because we can't edit in Visual Studio Properties Window) and set GenerateDefaultFixedNodes property to "No" (default is "Yes").
If we set this property to "No" the result XML is the correct:
<ns0:Root xmlns:ns0="http://MappingError.DestinationSchema" />
<element1>
<field11>element1_0</field11>
<field12>element2_0</field12>
</element1>
<element3>
<field31>element3_0</field31>
</element3>
</ns0:root>