<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: BDC and BAPI in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469389#M220771</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;BDC using BAPI is handled by calling the BAPI by passing the import parameters and getting the export parameters of the FM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After execution of the BAPI, check the return Parameter BAPIRET2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If BAPIRET2-TYPE field is 'S' its success.&lt;/P&gt;&lt;P&gt; Possible values for TYPE&amp;gt;&amp;gt;&lt;/P&gt;&lt;P&gt; S = success message &lt;/P&gt;&lt;P&gt; E = error message &lt;/P&gt;&lt;P&gt; W = warning message &lt;/P&gt;&lt;P&gt; I = information message&lt;/P&gt;&lt;P&gt; A = termination message (abort)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Some fields in BAPIRET2 are described as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ID(CHAR 20): Message ID The structure BAPIRET2 takes into account the name space extension for the message class as of Release 4.0. If you want messages to be compatible with earlier R/3 Releases, use the message classes before Release 4.0.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;NUMBER: Message number&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;MESSAGE(CHAR 220)Full message text from the message table. All variables (in fields Message_V1 to Message_V4) have been replaced with text.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;There are some more fields you can use refer : &lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/a5/3ec9f74ac011d1894e0000e829fbbd/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/a5/3ec9f74ac011d1894e0000e829fbbd/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now after checking the status/TYPE in BAPIRET2, you can update the file. May be create an additional Column in your internal table and keep updating the same about SUCCESS/FAIL and DOWNLOAD the ITAB to file or create dataset from ITAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vishal&lt;/P&gt;&lt;P&gt;**Reward if helpful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 25 Aug 2006 07:44:17 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-08-25T07:44:17Z</dc:date>
    <item>
      <title>BDC and BAPI</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469387#M220769</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;    Can anyone explain how we can trap error in BDC if we are using BAPI Function Module. And also how the errors trapped are displayed in a flat file. Can anyone help me out with an example.&lt;/P&gt;&lt;P&gt;Thanks in Advance,&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Rijish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Aug 2006 07:08:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469387#M220769</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-25T07:08:25Z</dc:date>
    </item>
    <item>
      <title>Re: BDC and BAPI</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469388#M220770</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In BAPI, you can check the RETURN table parameter of the BAPI. So, check this table parameter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Aug 2006 07:31:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469388#M220770</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2006-08-25T07:31:06Z</dc:date>
    </item>
    <item>
      <title>Re: BDC and BAPI</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469389#M220771</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;BDC using BAPI is handled by calling the BAPI by passing the import parameters and getting the export parameters of the FM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After execution of the BAPI, check the return Parameter BAPIRET2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If BAPIRET2-TYPE field is 'S' its success.&lt;/P&gt;&lt;P&gt; Possible values for TYPE&amp;gt;&amp;gt;&lt;/P&gt;&lt;P&gt; S = success message &lt;/P&gt;&lt;P&gt; E = error message &lt;/P&gt;&lt;P&gt; W = warning message &lt;/P&gt;&lt;P&gt; I = information message&lt;/P&gt;&lt;P&gt; A = termination message (abort)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Some fields in BAPIRET2 are described as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ID(CHAR 20): Message ID The structure BAPIRET2 takes into account the name space extension for the message class as of Release 4.0. If you want messages to be compatible with earlier R/3 Releases, use the message classes before Release 4.0.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;NUMBER: Message number&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;MESSAGE(CHAR 220)Full message text from the message table. All variables (in fields Message_V1 to Message_V4) have been replaced with text.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;There are some more fields you can use refer : &lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/a5/3ec9f74ac011d1894e0000e829fbbd/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/a5/3ec9f74ac011d1894e0000e829fbbd/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now after checking the status/TYPE in BAPIRET2, you can update the file. May be create an additional Column in your internal table and keep updating the same about SUCCESS/FAIL and DOWNLOAD the ITAB to file or create dataset from ITAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vishal&lt;/P&gt;&lt;P&gt;**Reward if helpful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Aug 2006 07:44:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469389#M220771</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-25T07:44:17Z</dc:date>
    </item>
    <item>
      <title>Re: BDC and BAPI</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469390#M220772</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi rijish,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in BDC...&lt;/P&gt;&lt;P&gt;u can use the FM FORMAT_MESSAGE..&lt;/P&gt;&lt;P&gt;CALL TRANSACTION 'FK01' USING IT_BDCDATA MODE 'A'&lt;/P&gt;&lt;P&gt;                        UPDATE 'S'&lt;/P&gt;&lt;P&gt;                        MESSAGES INTO IT_MESSAGES.&lt;/P&gt;&lt;P&gt;WRITe:/ SY-SUBRC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PERFORM FORMAT_MESSAGES.&lt;/P&gt;&lt;P&gt;form FORMAT_MESSAGES .&lt;/P&gt;&lt;P&gt;DATA: L_MSG(100).&lt;/P&gt;&lt;P&gt;LOOP AT IT_MESSAGES.&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'FORMAT_MESSAGE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;   ID              = IT_MESSAGES-MSGID&lt;/P&gt;&lt;P&gt;   LANG            = SY-LANGU&lt;/P&gt;&lt;P&gt;   NO              = IT_MESSAGES-MSGNR&lt;/P&gt;&lt;P&gt;   V1              = IT_MESSAGES-MSGV1&lt;/P&gt;&lt;P&gt;   V2              = IT_MESSAGES-MSGV2&lt;/P&gt;&lt;P&gt;   V3              = IT_MESSAGES-MSGV3&lt;/P&gt;&lt;P&gt;   V4              = IT_MESSAGES-MSGV4&lt;/P&gt;&lt;P&gt; IMPORTING&lt;/P&gt;&lt;P&gt;   MSG             = L_MSG&lt;/P&gt;&lt;P&gt; EXCEPTIONS&lt;/P&gt;&lt;P&gt;   NOT_FOUND       = 1&lt;/P&gt;&lt;P&gt;   OTHERS          = 2&lt;/P&gt;&lt;P&gt;          .&lt;/P&gt;&lt;P&gt;write:/ l_msg.&lt;/P&gt;&lt;P&gt;  endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endform.      &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IN BAPI..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;u can check the parameter RETURN..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this helps,&lt;/P&gt;&lt;P&gt;priya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Aug 2006 07:46:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469390#M220772</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-25T07:46:40Z</dc:date>
    </item>
    <item>
      <title>Re: BDC and BAPI</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469391#M220773</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi ,&lt;/P&gt;&lt;P&gt;After BAPI call loop thru return table for message type 'E' or 'A' , then you will get all error messages or abend messages.&lt;/P&gt;&lt;P&gt;call BAPI.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;if not return_table is initial.
loop at return_table where type = 'E' or type 'A'.
write:/ return_table-message.
endloop.
endif&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raghav&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Aug 2006 07:46:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-and-bapi/m-p/1469391#M220773</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-25T07:46:50Z</dc:date>
    </item>
  </channel>
</rss>

