how to access 5 days worth of data

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
ravikiran2712
Participant
Posts: 38
Joined: Thu Nov 04, 2004 10:36 am

how to access 5 days worth of data

Post by ravikiran2712 »

hi ,
i am developing a parallel job in which the design is as follows,


transformer-------> lookup<------- oracle.
the transformer outputs records in which i have a date field. i will have to look up into the oracle stage for the past 5 days worth of records depending on the date field output by the transformer.
please reply fast.
rk
kcbland
Participant
Posts: 5208
Joined: Wed Jan 15, 2003 8:56 am
Location: Lutz, FL
Contact:

Post by kcbland »

Your description of the job design is incomprehensible. Could you please restate the design and your requirements?
Kenneth Bland

Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle
ravikiran2712
Participant
Posts: 38
Joined: Thu Nov 04, 2004 10:36 am

Post by ravikiran2712 »

hi,
i will have to access previous 5 days(depending on the date field output by the transformer) from the oracle database stage.i mean i want the design which can be used to do this involving an oracle database stage a transformer and any processing stage.
thankyou
rk
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Is there a mechanism in the database table that allows you to answer the question "5 days worth"?
Then surely the simplest mechanism is to use an appropriate date difference function in the extraction SQL. For example

Code: Select all

SELECT columns FROM table WHERE datefield >= (sysdate - 5);
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
T42
Participant
Posts: 499
Joined: Thu Nov 11, 2004 6:45 pm

Post by T42 »

You can also pass the date field from Oracle, and match it with the valid date fields from the Transformer. Yes, a lot of duplications. Range matching is not available just yet (coming soon...)
Post Reply