Difference between merge and Union All transformation
- Merge transformation requires sorted input to process data but union all does not need any sorted input.
- Union All is always faster than merge transformation
- Merge allows only two inputs but union all allows more than two inputs.
- Merge do not allow single input but union all allows single input.
- Both the transformation are considered as semi blocking
- Both transformations allow duplicate outputs.
Performance consideration while using merge transformation
If you have a scenario where you need to have sorted output then do not use sort transformation rather use sorting at source query preferably ORDER BY if you are using T-SQL.
If you feel that sorting is not required in your use case then Union All is the preferable transformation over Merge.
No comments:
Post a Comment