How to use Duplicate rule in Mapping

Please find the rule in the attached screenshot to check the duplicate entry of EmpSSN and ElectionCode repeats in more than one record in a source file. Then, there will be no duplicacy and only one unique record will be picked up from the source file.


These two axis functions worked as defined below:

  • Preceding: Selects all nodes that appear before the current node in the document, except ancestors, attribute nodes and namespace nodes.
  • Following: Selects everything in the document after the closing tag of the current node.
Have more questions? Submit a request


  • 0
    David Paras

    Want to update a column in case of duplicate records. Or filter out both records?

    Use below For each condition:

    /Root/Record [(preceding:: Material = Material) or (following:: Material = Material)]

    What if I need to filter both the duplicates?

    for Filtering both the duplicates(preceding and following) you need to apply both the Axis Functions "preceding" as well as "following" in ForEach.

    Apply the below ForEach condition to filter both the duplicates:

    "$Input_Source_Schema/Root/Record[not(preceding::Source_Column1 = Source_Column1) and not(following::Source_Column1 = Source_Column1) ]"

Article is closed for comments.