CAPTURING THE DELETEDRECORDS...............

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
akansha123
Participant
Posts: 9
Joined: Sat Mar 18, 2006 1:53 pm

CAPTURING THE DELETEDRECORDS...............

Post by akansha123 »

Hai,
Can anyone tell me how to catch catch the deleted records while performing CDC(Change Data Capture)
AKANSHA
samsuf2002
Premium Member
Premium Member
Posts: 397
Joined: Wed Apr 12, 2006 2:28 pm
Location: Tennesse

Post by samsuf2002 »

make the "drop deletes" option equal false in CDC.
hi sam here
meena
Participant
Posts: 430
Joined: Tue Sep 13, 2005 12:17 pm

Post by meena »

Hi,
Move this to Parallel Forum.
gateleys
Premium Member
Premium Member
Posts: 992
Joined: Mon Aug 08, 2005 5:08 pm
Location: USA

Post by gateleys »

It seems he is on Server and means the CDD technique and not the stage (as available in EE). Akansa, in order that the deleted rows are accounted for, you will have to maintain an image of the previous load. Only then will you be able to do what you were asking for. There was a job design that was posted here some time back which dealt with this, interestingly; but I just could not find it.

gateleys
akansha123
Participant
Posts: 9
Joined: Sat Mar 18, 2006 1:53 pm

Post by akansha123 »

Its a server job and iam using hash file to capture the changed and unchanged data using CRC32 function but also need to capture the deleted data
AKANSHA
kris007
Charter Member
Charter Member
Posts: 1102
Joined: Tue Jan 24, 2006 5:38 pm
Location: Riverside, RI

Post by kris007 »

To capture records from target table which are no longer present in the source you can do the following:

Read all the Keys from the Target. This is your primary input. Load all the keys from the source in the hashed file and use that as lookup. Now bring out only those rows from your target which don't have a match in your hashed file and set your update action as "Delete existing rows" and that will delete all the records in the target. Now to capture them, just write those rows to a sequential file instead of deleting. It's upto your requirement.

IHTH
Kris

Where's the "Any" key?-Homer Simpson
meena
Participant
Posts: 430
Joined: Tue Sep 13, 2005 12:17 pm

Post by meena »

I thought this is regarding chage capture stage. :?
meena wrote:Hi,
Move this to Parallel Forum.
.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Nope. Turns out to be a wrong choice of terminology... as noted later, the OP is actually attempting CDD.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply