Passing BAPI  Error Messages to BDC  Session.

Hi,
Can any one drive the idea how to convert rather passing BAPI error messages into BDC session.
regards.

Naveen,
I am sure you already have the logic of "If the call transaction is errored out you create a BDC session for the same data".
Now, when your BAPI fails, irrespective of the error, you need to build the BDCDATA table and pass the data to the session. So, I don't you really need to know the errors and pass them to the BDC Session.
Check the RETURN table of the BAPI, if it has got E / A / X error types then you can build the BDCDATA table and create the session.
Regards.
Ravi
Note : Please mark the helpful answers and close the thread if the issue is resolved.

Similar Messages

  • Help! I have recently updated LR5 and before doing so I was able to email files to clients! (Very Convenient) Now my problem is I have not been able to get pass this error message reading "failed to send" which gives no further detail about what to do to

    Help! I have recently updated LR5 and before doing so I was able to email files to clients! (Very Convenient) Now my problem is I have not been able to get pass this error message reading "failed to send" which gives no further detail about what to do to rectify the situation. Someone please guide me through this! Thanks in advance!

    Did this ever get resolved, as I am having the same issue.  Trying to learn LR5 AFTER a decade using Aperture.   I was able to set up a validated account but when I try to send an e-mail or photo I get the simple " Failed to Send " message.   Using latest version of Mac OS X.

  • BAPI Error Message Handling

    Hi Group,
    I am using BAPI ,How to display the BAPI  Error Message (eg:BAPIRET1) which is returning by BAPI

    HI ,
    ITS SIMPLE TRY THIS CODE
    AWARD PTS
    DATA: gt_ret     TYPE TABLE OF bapiret2,
               ls_ret    TYPE bapiret2,
    CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
        EXPORTING
          salesdocument     = p_vbeln
          order_header_in   = gt_hdr
          order_header_inx  = gt_hdrx
        TABLES
          return            = gt_ret -
    >>>>.<b>IMPORTANT</b>
          order_item_in     = gt_itm
          order_item_inx    = gt_itmx
          schedule_lines    = gt_sched
          schedule_linesx   = gs_schedx
          order_text        = gs_stdtxt.
          PARTNERS          = gs_partner
      CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
      LOOP AT gt_ret INTO ls_ret.
        WRITE:/ ls_ret-type.
        WRITE:/ ls_ret-message.
      ENDLOOP.

  • Error in my BDC SESSION METHOD

    Hi,
    I was trying work on BDC SESSION METHOD AND MY TCODE IS XK01.
    Here is my code can some one tell me where i am doing wrong becoz its not giving the output as I expected. And I am uploading a tab delimeter file.
    report ZAN_BDCVENDOR
           no standard page heading line-size 255.
    include bdcrecx1.
    DATA: I_BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE.
    DATA: BEGIN OF RECORD OCCURS 0,
    LIFNR(016),
    BURKS(004),
    EKORG(004),
    KTOKK(004),
    AKONT(010),
    FDGRV(010),
    WAERS(005),
    END OF RECORD.
    start-of-selection.
    perform open_group.
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        filename                      = 'C:\VENDOR.TXT'
    FILETYPE                      = 'ASC'
      tables
        data_tab                      = RECORD
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    LOOP AT RECORD.
    perform bdc_dynpro      using 'SAPMF02K' '0100'.
    perform bdc_field       using 'BDC_CURSOR'
                                  'USE_ZAV'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '/00'.
    perform bdc_field       using 'RF02K-LIFNR'
                                  '8765'.
    perform bdc_field       using 'RF02K-BUKRS'
                                  '1000'.
    perform bdc_field       using 'RF02K-EKORG'
                                  '1000'.
    perform bdc_field       using 'RF02K-KTOKK'
                                  '0001'.
    perform bdc_field       using 'USE_ZAV'
                                  'X'.
    perform bdc_dynpro      using 'SAPMF02K' '0210'.
    perform bdc_field       using 'BDC_CURSOR'
                                  'LFB1-FDGRV'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '=UPDA'.
    perform bdc_field       using 'LFB1-AKONT'
                                  '160000'.
    perform bdc_field       using 'LFB1-FDGRV'
                                  'A1'.
    perform bdc_dynpro      using 'SAPMF02K' '0310'.
    perform bdc_field       using 'BDC_CURSOR'
                                  'LFM1-WAERS'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '=UPDA'.
    perform bdc_field       using 'LFM1-WAERS'
                                  'usd'.
    perform bdc_transaction using 'XK01'.
    ENDLOOP.
    perform close_group.
                  CALL FUNCTION 'BDC_OPEN_GROUP'
                   EXPORTING
                    CLIENT                    = SY-MANDT
                    DEST                      = FILLER8
                     GROUP                     = 'SESSION1'
                    HOLDDATE                  = FILLER8
                    KEEP                      = FILLER1
                     USER                      = SY-UNAME
                    RECORD                    = FILLER1
                    PROG                      = SY-CPROG
                  IMPORTING
                    QID                       =
                  EXCEPTIONS
                    CLIENT_INVALID            = 1
                    DESTINATION_INVALID       = 2
                    GROUP_INVALID             = 3
                    GROUP_IS_LOCKED           = 4
                    HOLDDATE_INVALID          = 5
                    INTERNAL_ERROR            = 6
                    QUEUE_ERROR               = 7
                    RUNNING                   = 8
                    SYSTEM_LOCK_ERROR         = 9
                    USER_INVALID              = 10
                    OTHERS                    = 11
                  IF sy-subrc <> 0.
                  WRITE 'ERROR IN OPEN_GROUP'.
                  ENDIF.
                   CALL FUNCTION 'BDC_INSERT'
                   EXPORTING
                     TCODE                  = TCODE
                     POST_LOCAL             = NOVBLOCAL
                     PRINTING               = NOPRINT
                     SIMUBATCH              = ' '
                     CTUPARAMS              = ' '
                     TABLES
                       dynprotab              = I_BDCDATA
                   EXCEPTIONS
                     INTERNAL_ERROR         = 1
                     NOT_OPEN               = 2
                     QUEUE_ERROR            = 3
                     TCODE_INVALID          = 4
                     PRINTING_INVALID       = 5
                     POSTING_INVALID        = 6
                     OTHERS                 = 7
                   IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
                   ENDIF.
                   CALL FUNCTION 'BDC_CLOSE_GROUP'
                   EXCEPTIONS
                     NOT_OPEN          = 1
                     QUEUE_ERROR       = 2
                     OTHERS            = 3
                   IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
                   ENDIF.
    I appreciate

    Hi,
    i guess, the error is due to, u didnt pass the TCODE parameter in BDC_INSERT FM.
    Try by passing it...
    CALL FUNCTION 'BDC_INSERT'
    EXPORTING
    TCODE = TCODE*
    POST_LOCAL = NOVBLOCAL
    PRINTING = NOPRINT
    SIMUBATCH = ' '
    CTUPARAMS = ' '
    TABLES
    dynprotab = I_BDCDATA
    EXCEPTIONS
    INTERNAL_ERROR = 1
    NOT_OPEN = 2
    QUEUE_ERROR = 3
    TCODE_INVALID = 4
    PRINTING_INVALID = 5
    POSTING_INVALID = 6
    OTHERS = 7
    Hope it works!!
    Regards,
    Pavan

  • Error message log in session method of ALV report,

    In ALV report please let me know:
    1) In session method:
    where all error messages are stored,I know that error messages are stored in a log file, so please tell me where is it stored.
    2)transaction method:
    How to handle error messages in transaction methos(for eg if a weight field text box value is negative)

    Ans for 2nd point.
    CALL TRANSACTION c_mb USING i_bdcdata
                              MODE g_ctumode
                              UPDATE g_cupdate
                              MESSAGES INTO i_messtab.
       COMMIT WORK.
       IF sy-subrc EQ 0. " BDC Executed Successfully
         CLEAR wa_messtab.
         LOOP AT i_messtab INTO wa_messtab .
           IF wa_messtab-msgtyp  = 'S' AND
              wa_messtab-msgid   = 'M7' AND
              wa_messtab-msgnr   = '060'.
             CALL FUNCTION 'MESSAGE_TEXT_BUILD'
               EXPORTING
                 msgid               = wa_messtab-msgid
                 msgnr               = wa_messtab-msgnr
                 msgv1               = wa_messtab-msgv1
                 msgv2               = wa_messtab-msgv2
                 msgv3               = wa_messtab-msgv3
                 msgv4               = wa_messtab-msgv4
               IMPORTING
                 message_text_output = l_msg.
             APPEND l_msg TO i_sucsess.
             CLEAR l_msg.
             g_docsuc = 1.
           ELSE.
             IF wa_messtab-msgtyp  = 'E'.
               CALL FUNCTION 'MESSAGE_TEXT_BUILD'
                 EXPORTING
                   msgid               = wa_messtab-msgid
                   msgnr               = wa_messtab-msgnr
                   msgv1               = wa_messtab-msgv1
                   msgv2               = wa_messtab-msgv2
                   msgv3               = wa_messtab-msgv3
                   msgv4               = wa_messtab-msgv4
                 IMPORTING
                   message_text_output = l_msg.
               g_errflg = 1.
               APPEND l_msg TO i_error.
               CLEAR: l_msg.
             ENDIF.

  • Error Message from BDC program

    Hi all,
    I'm facing the following situation: when i run a call transaction program for VL01:
      DATA:   MESSTAB LIKE BDCMSGCOLL OCCURS 0 WITH HEADER LINE.
      CALL TRANSACTION 'VL01N' USING bdcdata MESSAGES into MESSTAB.
    sometimes when an item has no stock, i get the error message:
        MSGTYP = E
        MSGID = VL
        MSGNR = 643
        MSGV1 = '1'
        MSGV2  = 'UN'.
        MSGV3 = ''
        MSGV4 = ''
      the problem: when i compose this message with FM - FORMAT_MESSAGE, i dont get the material code, to wich the loss os stock error referes to, since is not returned from call transaction execution (in messtab). How can i determine to which material code the error refers to ?
      As anyone faced the same situation ?
       Best regards,
    Pedro Castro

    If you know the material number which you passed to the BDC, you can simply use that, if you are passing mulitple materials for one call of the BDC, then I don't think you can know which material it is erroring on if the message does not bring it back.
    Regards,
    RIch Heilman

  • How to handle error messages in BDC background mode

    Hi experts,
      I got one problem in BDC, We are uploading data throgh BDC program,that program is calling Standard Batch Input programs,
    Now we got one requirement, i.e., In some special cases we have to send one message as a error message.I handled this in foreground but, how to handle this in background.

    Hi,
    if session is being used
    automatically the log will begenereated in the sm35 transaction
    but if call transaction is used
    put all the error messages in the applicationserver using
    open data set
    and after the exectionof the program in the background
    you have to run another progam which reads the data stroed inthe application server
    that also with open data set only...
    thanks & regards,
    Venkatesh

  • How to capture the error messages from incorrect session?

    Hi SDNs.,
    i am using BDC Session method to update transaction FB01. So my job runs daily. here i want to capture the error messages and i want to send it to mail.  Can i capture the unprocessed records???
    i think FM <b>SO_NEW_DOCUMENT_ATT_SEND_API1</b> used for sending mail? but how to capture mes or records?
    or Is there any other way to Do it???
    Thankning you.,
    Ram

    Hi Ramakrishna,
       Once you create the session, Process the session using
    the report RSBDCSUB using submit statement.
    It would list out the erroneous records.
    Hence, while submitting, just say submit RSBDCSUB in background and export output list to memory.,
    Then you can retrieve the list from memory using the FM LIST_FROM_MEMORY into the internal table and finally send the email by the fm you have already mentioned.
    Regards,
    Ravi

  • BAPI Error message in WDA using AIF

    Friends,
    I am working on Custom WDA using AIF to create Purchase Requisitions.
    I am calling the BAPIs  -  'BAPI_REQUISITION_CREATE' and 'BAPI_TRANSACTION_COMMIT' using CALL FUNCTION.
    I passed the item values to zitab and called the function module.
    Here is the code:
    CALL FUNCTION 'BAPI_REQUISITION_CREATE'
    EXPORTING
    SKIP_ITEMS_WITH_ERROR                = 'X'
    AUTOMATIC_SOURCE                     = 'X'
    IMPORTING
    NUMBER                               = number
    TABLES
       REQUISITION_ITEMS                    = zitab
      REQUISITION_ACCOUNT_ASSIGNMENT       =
      REQUISITION_ITEM_TEXT                =
      REQUISITION_LIMITS                   =
      REQUISITION_CONTRACT_LIMITS          =
      REQUISITION_SERVICES                 =
      REQUISITION_SRV_ACCASS_VALUES        =
      RETURN                               = zbapireturn
      REQUISITION_SERVICES_TEXT            =
      REQUISITION_ADDRDELIVERY             =
      EXTENSIONIN                          =
    I am getting the following error messages from BAPI_REQUISITION_CREATE:
    1. Message type - E
    Code - W5069
    Message - Please also pass on a unit of measure for the quantity
    2. Message type - E
    Code - W5002
    Message - No items exist (not possible to save)
    Here are the relevant details:
    System - SAP ECC 6.0 EhP4
    Adobe Livecycle Designer version  - 8.1.2.4246.1.597341
    ADS version - 802.20100318013254.656549
    I found this link that is relevant to the second error, thought the solution is not provided:
    Error : No items Exists (Not Possible to save)
    I would appreciate any hints or thoughts on how to get these errors rectified.
    Regards,
    Arun.

    Thanks Kris for your reply.
    I was able to rectify the 2 errors.
    I need to update 5 custom fields in the CI_EBANDB include in the EBAN table. I am using the EXTENSIONIN parameter.
    Here is my code:
    data: wa_bapiextn type bapiparex,
          zbapiextn type table of bapiparex.
      wa_bapiextn-structure = 'CI_EBANDB'.
      wa_bapiextn-VALUEPART1 = 'A'.
      wa_bapiextn-VALUEPART2 = 'B'.
      wa_bapiextn-VALUEPART3 = 'C'.
      wa_bapiextn-VALUEPART4 = 'D'.
      append zstruct to zitab.
      append wa_bapiextn to zbapiextn.
    CALL FUNCTION 'BAPI_REQUISITION_CREATE'
    * EXPORTING
    *  SKIP_ITEMS_WITH_ERROR                = 'X'
    *  AUTOMATIC_SOURCE                     = 'X'
      IMPORTING
        NUMBER                               = number
        TABLES
          REQUISITION_ITEMS                    = zitab
    *   REQUISITION_ACCOUNT_ASSIGNMENT       =
    *   REQUISITION_ITEM_TEXT                =
    *   REQUISITION_LIMITS                   =
    *   REQUISITION_CONTRACT_LIMITS          =
    *   REQUISITION_SERVICES                 =
    *   REQUISITION_SRV_ACCASS_VALUES        =
         RETURN                               = zbapireturn
    *   REQUISITION_SERVICES_TEXT            =
    *   REQUISITION_ADDRDELIVERY             =
        EXTENSIONIN                          = zbapiextn
    The custom fields are not getting updated. I would greatly appreciate any hints on how to get these custom fields updated.
    Regards,
    Arun.

  • Cannot sync. Error message says "sync session failed to start"

    I am not able to sync my ipod. The error message "the ipod could not be synced because the sync session failed to start" keeps popping up. I have tried both syncing it plugged in and by wifi and the same message appears

    Same problem today. Took five times to reinstall without any error messages. Apple has posted a way to fix and you should follow their's first. I finally got to upldate correctly by doing their fix but with one difference. I did the following:
    1) Went to the C:\program files (x86)\iTunes and C:\program files\iTunes folders and moved every file ending in .dll to the desktop (even if two files in same location had the same name, just replace)
    2) Restarted computer and still got error message
    3) Uninstalled all apple programs possible in the following order......itunes, apples software update, apple mobile device support, bonjour, and apple application support.....all performed using the microsoft control panel
    4) put all the .dll files on the desktop in the trash and emptied (this is a step apple support did not specifically put in their fix but for a final try I wanted to delete everything apple).
    5) Restarted computer.
    6) Re-installed itunes from apple website
    No error messages during re-install and was able to open shortcut in one try. Even updated my ipad to make sure everything was working.

  • Error message from iTunes session ID unavailable

    When updating or synching will get the error message "iTunes unable to connect with this iPhone, session ID unavailable".  I click OK then the message goes away, but I have absolutely no idea what that means, if the updates and items synchronized, or the whole thing will blow up sometime.  Cannot find session ID anywhere in the FAQ or Help files.

    Hello, Hilsco. 
    Thank you for visiting Apple Support Communities. 
    Here is an article that I would recommend going through when receiving this error message.  Also, make sure your computer has the correct date and time set as this could cause this issue. 
    Troubleshoot issues on a Mac
    If you haven't been able to connect to the iTunes Store, a software conflict or your Internet service provider (ISP) may be blocking your access.
    Update iTunes and Safari to the latest version.
    If you have a firewall, your settings may be preventing you from connecting to the iTunes Store. Follow these steps to configure your firewall.
    You may need to reset your keychain. Connection issues are occasionally caused by keychain issues. Learn how to use Keychain First Aid to resolve any issues with your keychain.
    If you're receiving a specific error message, follow these steps.
    If the issue still persists, contact your Internet service provider and confirm that these ports and servers are enabled over your network.
    Can't connect to the iTunes Store
    http://support.apple.com/kb/ts1368
    Cheers,
    Jason H. 

  • I get an error message 'Cannot create session cookie'

    Hello,
    This is the exact error message I receive:
    "Time: 2011-04-05 14:47:47
    OUCU: zz767748
    URL: /science.level1ayrf.s104/
    TN: openmark @ ltsweb2
    Status: 403
    Title: Unable to create session cookie
    Message: In order to use this website you must enable cookies in your browser settings."
    Many thanks,
    Rachel

    No idea what causes it, but it does happen. Try this.....
    Go to Settings>General>Date and Time>Set Automatically>Off. Set the date one year ahead. Try to update the apps again. If you get an error message, go back to the settings. Correct the date and time (set automatically) then go back and try to update the apps again.
    Or this ....
    If that doesn't work - sign out of your account, restart the iPad and then sign in again.
    Settings>Store>Apple ID. Tap your ID and sign out. Restart the iPad by holding down on the sleep button until the red slider appears and then slide to shut off. To power up hold the sleep button until the Apple logo appears and let go of the button.
    Go back to Settings>Store>Sign in and then try to update again.

  • Want to output Error message in BDC recording(PA30)

    Hi all,
    Currently iam working on upload program,whic is done by BDC recording with transaction PA30.while loading the data to different infotypes,iam checking one condition
    in particular infotype,after that i need to give the error message(Type E) and i data should not get uploaded for that infotype,and it has to go to next infotype.i want to log this error also,how can i do this?

    The ERROR message will stop the processing of the program,  the message will need to be either an I(information) or a W(warning) message into for the program to continue processing.
    Log the message by writing it to an internal table.
    IF SOME_CONDITION = 'X'.
    MESSAGE W001(00) with 'Hey, here is a message'.
    itab-pernr = p_pernr.
    itab-msgid = '00'.
    itab-msgno = '001'.
    append itab.
    ENDIF.
    CALL TRANSACTION 'PA30'........
    Regards,
    Rich HEilman

  • Strange error message.  Same session id with different ip addresses.

    Below is the error message that is being logged by apache. This started happening a few days ago. For every error log entry there is also an entry in the access log file. See below.
    error log entry
    [Mon Apr 27 13:03:47 2009] [error] [client 74.86.9.148] [ecid: 4573462121620,1] mod_plsql: /pls/apex/f HTTP-404 \nf: SIGNATURE (parameter names) MISMATCH\nVARIABLES IN FORM NOT IN PROCEDURE: P_FLOW_ID,P_FLOW_STEP_ID,P_INSTANCE,P_PAGE_SUBMISSION_ID,P_REQUEST,P_ARG_NAMES,P_T01,P_ACCEPT_PROCESSING,P_MD5_CHECKSUM\nNON-DEFAULT VARIABLES IN PROCEDURE NOT IN FORM: \n
    access log entry
    74.86.9.157 - APEX_PUBLIC_USER [27/Apr/2009:14:24:00 -0400] "POST /pls/apex/f?p=100:8:4616411304461606::NO::: HTTP/1.1" 404 216
    74.86.43.217 - APEX_PUBLIC_USER [27/Apr/2009:14:24:10 -0400] "POST /pls/apex/f?p=100:8:4616411304461606::NO::: HTTP/1.1" 404 216
    75.126.57.125 - APEX_PUBLIC_USER [27/Apr/2009:14:24:18 -0400] "POST /pls/apex/f?p=100:8:4616411304461606::NO::: HTTP/1.1" 404 216
    notice the session id is the same in the three examples above, but they have different ip addresses...should this be? I'm not sure what this means. Is this a hack or an error on my page? I'm leaning more to a hack because when I access the same page I don't get the error message at all. Any ideas on what I should do would be great.

    Internet – can’t connect - Yosemite
    Internet – can’t connect - Yosemite (2)
    Wi-FI connection drops
    Wi-Fi Problems in OS X Yosemite
    Wi-Fi Problems in OS X Yosemite (2)
    Also try turning off Bluetooth.
    Troubleshooting Wi-Fi issues in OS X
    Wireless Connection Problems - Fix
    Wireless Connection Problems - Fix (2)
    Wireless Connection Problems - Fix (3)
    Wireless Connection Problems - Fix (4)

  • Bapi error messages, explainations

    Hi All,
    I am working on implementing a Bapi and we are getting a number of different error message returned. for instance one code we are getting is 'SAP Error Code #E-M8-074' = 'Quantity entered larger than quantity to be debited'
    but we can post the voucher manually when we enter the data in the system.
    what is the best way to trouble shoot this issue?
    looking forward to hearing back from you.
    thank you for your time.

    I assume you have read the long text for this message.
    From the long text it appears you are trying to post a subsequent debit or credit.  Is that correct?
    If so, has an invoice been posted for this purchase order?  You cannot post a subsequent debit/credit without at least one invoice posting.
    If an invoice has been posted what was the invoice quantity?  The error is occurring because you are trying to post the invoice against a quantity great than the invoice quantity.

Maybe you are looking for

  • Bug: white rectangle in corner of frame under windows

    First, I know I should post a bug report, but I cannot supply source code for this problem as I can only replicate using our whole product (proprietary source). Under Windows only (never Linux), when using 1.4.0, I sometimes get a white rectangle app

  • Is apple going to make an iphone 6

    Just wondering if i should buy an iphone 5 or wait until an iphone 6 comes out

  • Tcp 2006 connection

    Hi again all! Until recently (thanks to the folks who helped my other problem here last week - much appreciated!)  it's been a while since I programmed my last vi's  - almost 2 years in fact! - and I need a slight bit refreshing on programming a TCP2

  • [SOLVED] Using arguments in Bash Alias

    Hi all! I'm not very well-versed in the  art of bash scripting or anything and I am having some trouble doing an alias that uses two arguments. My case: My command: "openssl aes-256-cbc -a -salt -in a.txt -out a.txt.aes" What I wanted to do was an al

  • My account logout all the time

    please help me , i dont know why my account start to logout at all my devices, laptop(windows) and tablet(android)