Timestamp

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
dsdevper
Premium Member
Premium Member
Posts: 86
Joined: Tue Aug 19, 2008 9:31 am

Timestamp

Post by dsdevper »

Hi

I am checking an input coloumn(timestamp),If it is blank
(white spaces),which is not a null value.Then i have to set to 01/01/1800.

input(timestamp) and output stages(date) are DB2

I tried If (input coloumn) = " " then StringToDate('01/01/1800',"%MM/%DD/%YYYY").

Then it is giving an error "APT_CombinedOperatorController(0),0: Data string ' ' does not match format '%yyyy-%mm-%dd %hh:%nn:%ss': an integer was expected to match tag %yyyy."

Thanks
Nagaraj
Premium Member
Premium Member
Posts: 383
Joined: Thu Nov 08, 2007 12:32 am
Location: Bangalore

Re: Timestamp

Post by Nagaraj »

Hi Ther can anyone tell me how to post a new Question?\
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Top Left : Post New Topic
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Nagaraj
Premium Member
Premium Member
Posts: 383
Joined: Thu Nov 08, 2007 12:32 am
Location: Bangalore

thanks :)

Post by Nagaraj »

ray.wurlod wrote:Top Left : Post New Topic
tkbharani
Premium Member
Premium Member
Posts: 71
Joined: Wed Dec 27, 2006 8:12 am
Location: Sydney

Post by tkbharani »

Try if (InputColumn) = '' then 01/01/1800

From your post it is clear that your input is timestamp or blank value, but what is your input datatype , is it Timestamp or string. what is your output datatype Date or Timestamp. Accordingly you can convert it to TimeStampToDate or DateToTimeStamp.

But Why StringToDate ?
Thanks, BK
Post Reply