Default format for Oracle timestamp.

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
dhelsley
Participant
Posts: 9
Joined: Thu Jan 05, 2006 9:23 am

Default format for Oracle timestamp.

Post by dhelsley »

I'm using a DRS stage to read a timestamp column from Oracle 8i. By default the generated SQL uses TO_CHAR with the format "YYYY-MM-DD HH24:MI:SS".

To get the milliseconds I end up changing the type of these columns to VarChar and overriding the derivation with TO_CHAR(<col>, 'YYYY-MM-DD HH24:MI:SS.FF').

Is there a way to change the default so I don't need to override it every time?

Thank you.

Dave.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

I don't recall 8i having TIMESTAMP data types but that doesn't change the answer - no, not that I'm aware of.
-craig

"You can never have too many knives" -- Logan Nine Fingers
kejuste
Premium Member
Premium Member
Posts: 11
Joined: Wed Jun 01, 2005 11:42 pm
Location: Brisbane, Australia

Post by kejuste »

I GUESS THAT IS ONLY WAY YOU CAN EXTRACT MILLISECONDS. TO_CHAR(A.TABLE, 'YYYY-MM-DD HH24:MI:SS.FF')
Kathy Juster
Post Reply