Posted: Thu Sep 26, 2002 2:11 pm Post subject: Date Format
Novice
Joined: 26 Sep 2002 Posts: 24
Hai,
I am getting the date value in Fri Sep 26 15:13:06 EDT 2003 format.And I have to transfrom this format to yyyy-mm-dd in WMQI. I am using the below code
SET TransDt = "InputBody"."Honda_Peoplesoft.ExportSchema.dtd"."DATAAREA"."ariba.core.HondaComCntl_Export"."HondaComCntlHdrTransDt";
SET YTransDt = EXTRACT(YEAR FROM TransDt);
SET MTransDt = EXTRACT(MONTH FROM TransDt);
SET DTransDt = EXTRACT(DAY FROM TransDt);
SET TTransDt = YTransDt || '/' || MTransDt || '/' || DTransDt ;
SET
"OutputRoot"."XML"."COMMIT_CNTRL_TRAN_CHECK_UPDATE"."MsgData"."Transaction"."COMCNTL_TRN_HDR"."TRANS_DT" = TTransDt;
It is giving me error at
SET TransDt = "InputBody"."Honda_Peoplesoft.ExportSchema.dtd"."DATAAREA"."ariba.core.HondaComCntl_Export"."HondaComCntlHdrTransDt";
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
Your input message does not have data in ESQL DATE format. ESQL date format is DATE 'yyyy-mm-dd' .. so you cannot assign your input data directly to DATE field.
Try using SUBSTRING function instead. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum