StringToDate("#date_2nd_month#")

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
Benny Domeij
Participant
Posts: 6
Joined: Mon Mar 07, 2005 2:43 am

StringToDate("#date_2nd_month#")

Post by Benny Domeij »

I have defined the parameter date_2nd_month the value 2008-07-31 as a string and in a transformer I've created the variable valid_to_villkor as a date with the expression StringToDate("#date_2nd_month#"). Why am I getting the output ***** to that variable?
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Try it without the double quotes and hashes - i.e.

Code: Select all

StringToDate(date_2nd_month)
prasanna_anbu
Participant
Posts: 42
Joined: Thu Dec 28, 2006 1:39 am

string to date

Post by prasanna_anbu »

I have used

If(LKP_To_TFM_Check_Null.transaction_dt = "") Then 13 else If(Len(LKP_To_TFM_Check_Null.transaction_dt)<11) Then 13 Else If(IsValid("date",StringToDate(LKP_To_TFM_Check_Null.transaction_dt[1,11],"%mmm %dd %yyyy"))) Then 0 Else 13


in this i have get NOV 3 2008 instead NOV 03 2008

or i have get ****** what can i do for this
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

prasanna_anbu - The question you asked has little to do with the thread, so it is best posed in a new thread - and since you have already done that, it won't get answered here.
Post Reply