Applies to: Marshalling data to XML only
Available: For mapped nodes only when the option Sort XML Output Records Using ORDER BY (default) has been selected from the XML Structure tab toolbar. On an element or attribute node that is mapped to a DB column or expression
Possible values:
|
|
Not currently set. You may check this node to group occurrences of this node by node value in the XML output from the marshalling operation. |
|
|
Occurrences of this node will be grouped together in ascending order by node value in the results of the marshal operation. |
|
|
Occurrences of this node will be grouped together in descending order by node value in the results of the marshal operation. |
Allora offers three options for sorting XML output nodes:
Sort XML Output Records Using ORDER BY (default)
Choose which option using the Select Sort/ORDER BY Method icon in the XML Structure toolbar.
This option is available if a node is mapped to a DB column or an expression. It is not available for nodes that are added to the mapping file without being mapped or nodes that are mapped to constants.
The options can be set on an attribute or an element and the field or expression to which the node is mapped is added to the SELECT statement automatically generated when marshalling. Results are ordered by value unlike when using Sort Children where results are ordered by tag.
When more than one field is used in the ORDER BY clause, you may want to set a sequence. For example, if you set ORDER BY on both employee ID and department name, you would want to order by department name first, then employee ID. Click Set ORDER BY Sequence in the XML Structure tab toolbar to open a dialog and set the sequence.
|
|
Overview of the project used in examples below. | |
|
1. |
No settings have been made in the XML Structure tab | |
|
2. |
XML output combines all PurchaseOrder nodes that have a matching value for the OrderID node. | |
|
3. |
XML output groups all matching elements (LineItem) together | |
|
4.
|
XML output contains records retrieved from the database using an ORDER BY clause | |
|
5. |
XML output generated using the Optimized Combine feature in the XML Structure tab. |
XML Structure Tab
Introduction to Combining Nodes in XML Output When Marshalling
Combining Duplicate Elements in XML Output
Customizing Combine Settings for XML Output