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
hargun
Participant
Posts: 188 Joined: Mon May 16, 2011 7:41 pm
Location: United States
Post
by hargun » Tue Oct 15, 2013 7:27 pm
hi,
i have design inserting from DB2 stage to oracle as target.
The column RATE_DATE(TIMESTAMP) in DB2 STAGE and target is oracle having RATE_DATE(DATE) as datatype.
i have tried by inserting the same timestamp to DATE datatype without any conversion and job work fine but i am not able to get the time only date is inserted.
Please help me on this.
Niv0599
Premium Member
Posts: 13 Joined: Tue Apr 10, 2012 11:47 am
Post
by Niv0599 » Tue Oct 15, 2013 8:00 pm
Did you look at the target data RATE_DATE in oracle table to see if the Timestamp portion is also stored.
Datastage is the best thing that happened to ETL
chulett
Charter Member
Posts: 43085 Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO
Post
by chulett » Tue Oct 15, 2013 8:18 pm
Declare the RATE_DATE column with a data type of Timestamp in the job.
-craig
"You can never have too many knives" -- Logan Nine Fingers
hargun
Participant
Posts: 188 Joined: Mon May 16, 2011 7:41 pm
Location: United States
Post
by hargun » Wed Oct 16, 2013 7:18 am
i am doing the same giving the timestamp datatype still storing the Date part only.
chulett
Charter Member
Posts: 43085 Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO
Post
by chulett » Wed Oct 16, 2013 7:27 am
How exactly are you verifying this? What does the insert SQL in the stage look like, does it include a TO_DATE function for this field?
-craig
"You can never have too many knives" -- Logan Nine Fingers
hargun
Participant
Posts: 188 Joined: Mon May 16, 2011 7:41 pm
Location: United States
Post
by hargun » Wed Oct 16, 2013 9:32 am
please find the SQL which the oracle stage generating
INSERT INTO DIM.STG_NAME(ASSIGNED_DATE) VALUES(:ASSIGNED_DATE).
IT doesn't include to_Date function for this field.