on 07-22-2009 6:50 PM
Hi,
We are having trouble with dates being returned by RFCs in Visual
Composer.
To test the problem I have created a simple RFC that returns todays
date using data type DATUM. When I run via SAPGui it returns 22.07.2009.
When I test this RFC service in Visual Composer, it returns the
date "Wed Jul 22 00:00:00 BST 2009". Interestingly this looks like a
timestamp.
When I use the RFC Service in a model and run it, it display the date
30/11/1921 which is obviously wrong.
We are having this problem across a number of RFC services.
Any ideas would be greatly appreciated.
Many Thanks
Gary
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Martin,
Thanks for the response. I think I followed your solution. This is obviously a bug in VC.
I changed the RFC to return a CHAR8 field that contained the date in the format YYYYMMDD (i.e. SAP internal date format). This is received into VC as a text field.
I then used the expression DATE(LEFT(@E_DATE,4),MID(@E_DATE,4,2),RIGHT(@E_DATE,2)) to assign the date string to the form field in VC.
I tried going via a Data Store value and using this as a default for my form field but this didn't work. I assume this is down to a timing issue (i.e. the form was displayed before the value got into the data store.
Thanks for the help
Gary
Hi Martin,
Thanks for the response. I think I followed your solution. This is obviously a bug in VC.
I changed the RFC to return a CHAR8 field that contained the date in the format YYYYMMDD (i.e. SAP internal date format). This is received into VC as a text field.
I then used the expression DATE(LEFT(@E_DATE,4),MID(@E_DATE,4,2),RIGHT(@E_DATE,2)) to assign the date string to the form field in VC.
I tried going via a Data Store value and using this as a default for my form field but this didn't work. I assume this is down to a timing issue (i.e. the form was displayed before the value got into the data store.
Thanks for the help
Gary
Hi
Check the following wiki link i think this will help -
https://wiki.sdn.sap.com/wiki/display/VC/DateandTime+Formats
If you have ant doubts please let me know.
Regards
Sandeep
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Gary,
Use DSTR function to change the date format. Check the below link for details.
http://help.sap.com/saphelp_nw70/helpdata/en/2b/6c37121f28462a8710c0c7493506dd/content.htm
Regards
Basheer
Edited by: Basheer on Jul 23, 2009 10:33 AM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.