how to store the no record passes through any active Stage

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
swarnkar
Participant
Posts: 74
Joined: Wed Jan 11, 2006 2:22 am

how to store the no record passes through any active Stage

Post by swarnkar »

Hi,

I am new to Datastage, I want to track the no. of records that have been passes through the transformar to the file or table in a separate file.

Basically job log in director having that count like

J3RmsS4Lor..T: DSD.StageRun Active stage finishing.
8756128 rows read from ToT
8756128 rows written to ToTable

but is there any method by which i can store these statistics to a file.

Thanks in advance.
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

Hi,
There are several ways. Do a search.
@INROWNUM/@OUTROWNUM functions can be simply used to keep track of the number of records being passes across transformer.
Impossible doesn't mean 'it is not possible' actually means... 'NOBODY HAS DONE IT SO FAR'
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Being new to DataStage, some of the advice you'll get will probably sound like Greek. If so, try taking the keywords and searching the forums here as pretty much any question you'd have has already been asked and answered. :wink:

Two more ways:

You can also create a new link in the job to an Aggregator stage, sending it pretty much any field that will never be null and tell it to 'count' them. You can even 'hard code' a value. The output, which can be written to a file, will match the output from the stage as long as the constraint on the links (if any) match.

You can also get this information after the job completes using the DSGetLinkInfo function with the DSJE.LINKROWCOUNT type. That's from memory, so may not be exactly right but should be close. Check your online help for the various 'DSGet' functions as they come in very handy.
-craig

"You can never have too many knives" -- Logan Nine Fingers
swarnkar
Participant
Posts: 74
Joined: Wed Jan 11, 2006 2:22 am

Post by swarnkar »

Thank you very much i think DSJE.LINKROWCOUNT is a good solution.
chulett wrote:Being new to DataStage, some of the advice you'll get will probably sound like Greek. If so, try taking the keywords and searching the forums here as pretty much any question you'd have has already been asked and answered. :wink:

Two more ways:

You can also create a new link in the job to an Aggregator stage, sending it pretty much any field that will never be null and tell it to 'count' them. You can even 'hard code' a value. The output, which can be written to a file, will match the output from the stage as long as the constraint on the links (if any) match.

You can also get this information after the job completes using the DSGetLinkInfo function with the DSJE.LINKROWCOUNT type. That's from memory, so may not be exactly right but should be close. Check your online help for the various 'DSGet' functions as they come in very handy.
swarnkar
Participant
Posts: 74
Joined: Wed Jan 11, 2006 2:22 am

Post by swarnkar »

THANK YOU VERY MUCH.
kumar_s wrote:Hi,
There are several ways. Do a search.
@INROWNUM/@OUTROWNUM functions can be simply used to keep track of the number of records being passes across transformer.
Post Reply