on 09-17-2009 4:39 PM
Hi Experts,
I am getting date-time in 2009-09-17 13:05:16 format. But I need to send it to database as 2009/9/17 1:05:16 PM format.
When date is 08 only 8 needs to be present. And time should be in AM/PM format. Please suggest..
Thanks,
Vishal
Hi Vishal,
source field --> datetrans function --> target.
Double click on datetrans fucntion and on source format put yyyy-MM-dd HH:mm:ss and in target format put yyyy/MM/dd K:mm:ss a
Copy and paste directly from here. If you write you may miss something. Then your output should be as expected.
Regards,
---Satish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vishal,
There is no standard functionlity for this. you have to write the UDF for converting the 24-hour time format to 12-hour time format. check the below link for the UDF code
http://codingforums.com/showthread.php?t=156800
Regards
Ramesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vishal,
Use the DateTrans function and provide the OutPut date format as : yyyy/M/dd HH:mm:ss
this will convert the 08 month to 8
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vishal,
You can make use of the Date Transformation function available in the stabdard functions if the SAP PI mapping editor. If some specific requiremenbt of handling time zone, then you need to write UDF.
Thanks
Ajay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
82 | |
10 | |
10 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.