Hi,
I am creating a job in which I want to insert one log record to my oracle table which has the jobname,number of rows processed and datetime stamp.
If I use a output link to my oracle it will insert for every input record. But i need only one record for a job. Is there any way of doing in Datastage.
Also I need to know in the transformation if I want to send a output to a link only once is it possible.
Thanks in advance
Rasi
Need only One output
Moderators: chulett, rschirm, roy
You could use the Aggregator stage to solve your first problem. Send a minimal amount of information down a seperate link to the Aggregator and use it's COUNT function. Pull that out, add the jobname and timestamp in a transform and send it off as one row to Oracle.
On the 'once' issue, depends on when you need the 'once'. If first is ok, then contrain the link with @INROWNUM=1. Last is more difficult unless you know how many input rows you have. Don't have a good answer for that one off the top of my head, really depends on what you need to do.
-craig
On the 'once' issue, depends on when you need the 'once'. If first is ok, then contrain the link with @INROWNUM=1. Last is more difficult unless you know how many input rows you have. Don't have a good answer for that one off the top of my head, really depends on what you need to do.
-craig
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact: