Calendar Dimension

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
agpt
Participant
Posts: 151
Joined: Sun May 16, 2010 12:53 am

Calendar Dimension

Post by agpt »

Hi All,

I want to implement Calendar Dimension table using transformer. My requirement is to create load this table with all the dates from 2000 to 2015, day of week, month, quarter etc. I can easily get last three values using functions but how do I populate the table with all the dates in this 15 years of span. I don't want to write all of these manually. Is there anyway where in I can give start date and end date and get everything in between implemented?
priyadarshikunal
Premium Member
Premium Member
Posts: 1735
Joined: Thu Mar 01, 2007 5:44 am
Location: Troy, MI

Post by priyadarshikunal »

Why not to use row generator and then keep adding dates in downstream transformer?
Priyadarshi Kunal

Genius may have its limitations, but stupidity is not thus handicapped. :wink:
agpt
Participant
Posts: 151
Joined: Sun May 16, 2010 12:53 am

Post by agpt »

can u pls be more specific?
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Check the documentation for the Row Generator stage, specifically the types of data it can generate.
-craig

"You can never have too many knives" -- Logan Nine Fingers
vinothkumar
Participant
Posts: 342
Joined: Tue Nov 04, 2008 10:38 am
Location: Chennai, India

Post by vinothkumar »

If you want to spend less time on this, use excel to create the dates. Save it as .csv file and then use this file in your job to get the other values and load.
agpt
Participant
Posts: 151
Joined: Sun May 16, 2010 12:53 am

Post by agpt »

Thanks Craig.... I got it....

Vinoth, I didn't want to write 15 years equivalent dates so.... anywez got the solution now. Thanks.
Post Reply