‎2006 Jun 13 9:05 PM
Hi,
I have date on my selection screen and updating fk02 using bdc.
date parameter has different format and date in fk02 has different format, which causing error while updating.
could you please let me know how to change date format, is there any settings need to be changed.
Thanks
rk
‎2006 Jun 13 9:08 PM
Normally date defualt settings will in user settings, you can go from menu system-utilities' users own data. or SU01 tcode.
There you set the detault date formats for a user.
Also irrespective of date format in bdc you can do by moving the date into char(10) field and then passing this into screen field in bdcdata table.
Regds
Manohar
‎2006 Jun 13 9:12 PM
hi raj how ur date format looks currently and what is the expected format?
Cheers,
Abdul Hakim
‎2006 Jun 13 9:16 PM
‎2006 Jun 13 9:17 PM
In BDc you can read user date format like this ..it reads from TR.SU3 . I`m using for every BDC. we have written a custom FM . we pass date and it`ll retrun as per user format
RETRIEVE USER PROFILE DATE SETTING
select single datfm
into user_setting
from usr01
where bname = sy-uname.
and then reformat it ...
Hope thisll give you idea!!
<b>P.S award the points.</b>
Good luck
Thanks
Saquib Khan
"Some are wise and some are otherwise"
‎2006 Jun 13 10:22 PM
Make sure that the person running the program and the person running the BDC have the same date formats in their profiles.
Rob
‎2006 Jun 13 10:51 PM
I am hoping that this is not a batch input session processing. I am assuming that this is a call transaction, in which case the person who is executing the program will be the one who will be executing the transaction.
‎2006 Jun 13 11:03 PM
In that case, writing the date to the BDC field should work, but it sounds like the date on the selection screen has a different format from the transaction. That's why I'm thinking session processing by different people.
Rob
‎2006 Jun 14 3:09 AM
Hi Raj,
<b>1</b>.
Assume P_begda is Selection-screen date.
<b>2</b>.
Declare one variable like this.
DATA :l_begda(10),
<b>3</b>.
Use the below statement before populating BDCDATA table
WRITE p_begda TO l_begda.
<b>4</b>.
Pass L_begda like this.
PERFORM bdc_field USING 'RP50G-BEGDA'
l_begda.
I think that this helps u .
<b>Thanks,
Venkat.O</b>
‎2006 Jun 14 3:29 AM
you could try moving the field first to a variable with type datum or sy-datum and pass that field to the field in the BDC. Use "move" or "write" not "=".
we cannot ask the user to change his/her settings in SU01.