Example 4: Split upon change of tag name of Element at depth 1.

Sample XML file orders_by_state.xml containing 50 ORDER elements
Method C on the Methods tab is used in this example
methodC
  • No items on the Options Tab are specified for this example including the root element which must be blank.
All elements at depth 1 in the source XML document are USA state names. There are five such elements. Five split files are created. Each contains one state element from the source XML file with all of the ORDER elements for that state. Note that no root element is specified in the Wizard because the element with the state name becomes the root in each split file. A root element could be specified should one wish to encapsulate the state element within a different root.

First two split files created are below:

Split file 1.

Split file 2.