cancel
Showing results for 
Search instead for 
Did you mean: 

String to Date Time conversion

former_member237514
Participant
0 Kudos

Hi All,

I have requirement like String to Date Time conversion.

Actually from idoc Date is coming as string format but target excepting Date Time format for that i have to write the UDF .

Plz help me for the udf.

Thanks

Kavitha

Accepted Solutions (1)

Accepted Solutions (1)

former_member237514
Participant
0 Kudos

Hi All,

client excepted format:, 2002-10-10T12:00:00-05:00 .

previously i sent with out Milliseconds now i added that one .

now i can able to push the data to web service without any errors

Thanks

Kavitha

apu_das2
Active Contributor
0 Kudos

Please close the discussion if your requirement is met.

Thanks,

Apu

Answers (2)

Answers (2)

apu_das2
Active Contributor
0 Kudos

Hi Kavi tha,

If your source system itself is not sending you the time then basically there is no utilization of putting hhmmss in your target system as it always will be 000000.

If your requirement is just to match up your data with your target data structure then you can use standard date transformation function else in your case you can simply concatenate 000000 with your source data and send it to target system.

Thanks,

Apu

Harish
Active Contributor
0 Kudos

Hi Kavitha,

what is source data format in string and what is the format required in the target (date and time format)?

regards,

Harish

former_member237514
Participant
0 Kudos

Hi Harish,

Source format is  ddmmyyyy.

and target excepting ddmmyyyy hhmmss

former_member186851
Active Contributor
0 Kudos

Hello kavi,

No need of UDF, Try time functions in graphical mapping.

Give input format as ddmmYYYY(Caps/smalls might vary)

And target format as ddmmYYYY hhmmss(Caps/smalls might vary)

former_member237514
Participant
0 Kudos

Hi Raghu

I tried that one also but i am getting error.plz see the below

bhavesh_kantilal
Active Contributor
0 Kudos

Normally a DateTime can also include a milliseconds as SSS ( Upper Case ).

I would check with your Webservice provider what is the format required and then adjust accordingly as the format depends purely on how it is defined on their end.

Regards

Bhavesh

former_member237514
Participant
0 Kudos

Hi All,

we asked to client regarding format for date time ,They sent one link for reference .

XML Schema Part 2: Datatypes Second Edition

based on the above link i tested .but again i am getting the error.

plz give some idea about that error.

former_member237514
Participant
0 Kudos

Hi All,

Thanks for your suggestions .it working correctly.

bhavesh_kantilal
Active Contributor
0 Kudos

Please do post the actual timeformat that worked so if someone needs this info next time this is available! Just saying it works correctly helps no one!

Regards

Bhavesh