Hi All,
I had a requirement as follows.
I need to compare todays data and previous days data based on a key column and need to Insert new records and update the existing records...
scenario as follows...
previous day data
code
----
INR
USD
Todays data
code
----
INR
AUD
I need to compare the currency codes and If a new currency comes I need to insert the new record and update existing records.
And also I need to keep track of the new codes come in that day and existing codes which are not present in today's file
-------------------------------------
Resultant data need to contain as follows
Actual table
------------
code
----
INR
USD
AUD
Tracker table
-------------
AUD---New record
USD---Existing record which was not present in todays file
Any suggestions regarding what kind of stage I can use to do this scenario
Pls advise me
Kind Regards
Srini
How to maintain updated information as well as tracking
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 30
- Joined: Tue Feb 19, 2008 11:02 pm
-
- Premium Member
- Posts: 783
- Joined: Mon Jan 16, 2006 10:17 pm
- Location: Sydney, Australia
-
- Participant
- Posts: 334
- Joined: Fri Dec 01, 2006 5:17 am
- Location: Texas
hmmm...You can also use diff stage to achieve this purpose...keshav0307 wrote:Read the parallel job developers guide for change data capture stage
http://findingjobsindatastage.blogspot.com/
Theory is when you know all and nothing works. Practice is when all works and nobody knows why. In this case we have put together theory and practice: nothing works. and nobody knows why! (Albert Einstein)
Theory is when you know all and nothing works. Practice is when all works and nobody knows why. In this case we have put together theory and practice: nothing works. and nobody knows why! (Albert Einstein)
You can identify what is new & what is changed using CDC stage (Change Data Capture)
For new record Insert Code = 1
For Updated record Edit Code = 3
These codes are built-in in the CDC stage.
For new record Insert Code = 1
For Updated record Edit Code = 3
These codes are built-in in the CDC stage.
Quality is never an accident; it is always the result of high intention, sincere effort, intelligent direction and skillful execution; it represents the wise choice of many alternatives.
By William A.Foster
By William A.Foster