HowToCompare Data with in a file?
Moderators: chulett, rschirm, roy
-
ray.wurlod
- Participant
- Posts: 54595
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
There is technically no such thing as "the 51st row in a table". One of the precepts of normalized databases is that storage order is under control of the engine and neither controllable nor predictable.
Assuming therefore that you have a key by which the data are ordered during extraction, the task can easily be performed with stage variables. One can test the row number (to see whether Mod(@INROWNUM) = 1 And @INROWNUM > 1), another accumulates the total, and another determines whether the control record total matches the accumulated total. This last stage variable is used in (as?) the constraint expression on the two output links from the Transformer stage.
Assuming therefore that you have a key by which the data are ordered during extraction, the task can easily be performed with stage variables. One can test the row number (to see whether Mod(@INROWNUM) = 1 And @INROWNUM > 1), another accumulates the total, and another determines whether the control record total matches the accumulated total. This last stage variable is used in (as?) the constraint expression on the two output links from the Transformer stage.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
</a>