Microseconds as the default for DB2 timestamps

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
bmarko22
Participant
Posts: 21
Joined: Mon Nov 16, 2009 7:03 am
Location: MD

Microseconds as the default for DB2 timestamps

Post by bmarko22 »

Pulled the timestamp from a DB2 API stage and chose microseconds from the pull down in the extended options in order to get the milliseconds (2006-01-21-02.03.09.111111). I was wondering since it's a DB2 stage and it should always have milliseconds is there a way to at a project level or even server level have it default to always include microseconds? I tried changing the default in the project to something like %yyyy-%mm-%dd %hh:%nn:%ss:%cccccc but that didn't do the trick.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Try %ss.6 in the seconds position.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Moderator: please move to parallel forum
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
bmarko22
Participant
Posts: 21
Joined: Mon Nov 16, 2009 7:03 am
Location: MD

Post by bmarko22 »

ray.wurlod wrote:Try %ss.6 in the seconds position. ...
Fantastic! That worked. Thanks so much. I plan to set this as default in the table definitions defaults. Sorry I posted to wrong section.
bmarko22
Participant
Posts: 21
Joined: Mon Nov 16, 2009 7:03 am
Location: MD

Post by bmarko22 »

To have the default repeat in a project I at first made the change in a table definition and clicked on "make default" for all new table definitions. After which I found that in the Admin tool you can set the default format for the timestamp in the parallel tab. It asks you to uncheck "use system default" and then allows you to enter a new format. The fact that it has a "system format" there makes me think I am making this change in the wrong place. I'd love to have this format change be for the entire DS server. Is that something I can get at and change?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

No. DataStage is administered project by project.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply