Table of Contents

Search

  1. Preface
  2. Working with Transformations
  3. Aggregator Transformation
  4. Custom Transformation
  5. Custom Transformation Functions
  6. Data Masking Transformation
  7. Data Masking Examples
  8. Expression Transformation
  9. External Procedure Transformation
  10. Filter Transformation
  11. HTTP Transformation
  12. Identity Resolution Transformation
  13. Java Transformation
  14. Java Transformation API Reference
  15. Java Expressions
  16. Java Transformation Example
  17. Joiner Transformation
  18. Lookup Transformation
  19. Lookup Caches
  20. Dynamic Lookup Cache
  21. Normalizer Transformation
  22. Rank Transformation
  23. Router Transformation
  24. Sequence Generator Transformation
  25. Sorter Transformation
  26. Source Qualifier Transformation
  27. SQL Transformation
  28. Using the SQL Transformation in a Mapping
  29. Stored Procedure Transformation
  30. Transaction Control Transformation
  31. Union Transformation
  32. Unstructured Data Transformation
  33. Update Strategy Transformation
  34. XML Transformations

Transformation Guide

Transformation Guide

Sorting Data

Sorting Data

To use sorted input, you pass sorted data through the Aggregator.
Data must be sorted in the following ways:
  • By the Aggregator group by ports, in the order they appear in the Aggregator transformation.
  • Using the same sort order configured for the session. If data is not in strict ascending or descending order based on the session sort order, the Integration Service fails the session. For example, if you configure a session to use a French sort order, data passing into the Aggregator transformation must be sorted using the French sort order.
For relational and file sources, use the Sorter transformation to sort data in the mapping before passing it to the Aggregator transformation. You can place the Sorter transformation anywhere in the mapping prior to the Aggregator if no transformation changes the order of the sorted data. Group by columns in the Aggregator transformation must be in the same order as they appear in the Sorter transformation.
If the session uses relational sources, you can also use the Number of Sorted Ports option in the Source Qualifier transformation to sort group by columns in the source database. Group by columns must be in the same order in both the Aggregator and Source Qualifier transformations.
The following mapping shows a Sorter transformation configured to sort the source data in ascending order by ITEM_NO:
The mapping contains a relational source. A Sorter transformation occurs before an Aggregator transformation. The Sorter transformation groups data by item number. The Aggregator transformation connects to a target.
The Sorter transformation sorts the data as follows:
ITEM_NO
ITEM_NAME
QTY
PRICE
345
Soup
4
2.95
345
Soup
1
2.95
345
Soup
2
3.25
546
Cereal
1
4.49
546
Cereal
2
5.25
With sorted input, the Aggregator transformation returns the following results:
ITEM_NO
ITEM_NAME
TOTAL_QTY
INCOME_PER_ITEM
345
Soup
7
21.25
546
Cereal
3
14.99

0 COMMENTS

We’d like to hear from you!