Skip to Content
author's profile photo Former Member
Former Member

Date updation problem in BDC.

Hi all, very gud morning 😉

I have written a BDC program to a dialog UI screen,

So in dialog screen there is a date field, which wud be entered and updated.

So if v update the date, using screen its been updated into the database corectly.

ex: if i enter 30.05.2007, its updated as the same.

But if i have saved the data in a .txt file and if i update the database using BDC, its been updating as 30.05.2020 into the database instead of taking it as 30.05.2007

So do u knw watz the problem n solution for this?

Regards,

Sourav

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on May 30, 2007 at 06:17 AM

    Please make your date field as below because the txt format and sap formats are different for date .... so for any BDC the date's should followed as below .

    Date format for entry into BDC 
    
    Because a date field is stored and displayed in different formats within SAP the following code is 
    required to convert the date into a format which can be input onto a screen field.
    
     
    
    * Date field         
      data: ld_date(8).
      
      ld_date(2)   = sy-datum+6(2).
      ld_date+2(2) = sy-datum+4(2).
      ld_date+4(4) = sy-datum(4).
    
    
     
    

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on May 30, 2007 at 06:26 AM

    Hi Sowrabh,

    When ever you use the date in BDC define it as a char10 field.

    Check in the debugging what is the vaalue coming for this field.

    Regards,

    Atish

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on May 30, 2007 at 06:39 AM

    Hi,

    After getting the field into screen use the Conversion exit for ex.

    CONVERSION_EXIT_IDATE_INPUT

    this will solve your problem. pass the field to this as input and again as output

    Regards

    Shiva

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.