<?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 BDC call session in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963175#M946702</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hiii gurus! &lt;/P&gt;&lt;P&gt;I want to create a bdc for - VA01 - &amp;gt; VL01N (with PGI )-&amp;gt; VF0.&lt;/P&gt;&lt;P&gt;How can i implement BDC call session.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Points sure! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rahul&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 10 Jun 2008 06:24:15 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-06-10T06:24:15Z</dc:date>
    <item>
      <title>BDC call session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963175#M946702</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hiii gurus! &lt;/P&gt;&lt;P&gt;I want to create a bdc for - VA01 - &amp;gt; VL01N (with PGI )-&amp;gt; VF0.&lt;/P&gt;&lt;P&gt;How can i implement BDC call session.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Points sure! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rahul&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jun 2008 06:24:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963175#M946702</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-10T06:24:15Z</dc:date>
    </item>
    <item>
      <title>Re: BDC call session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963176#M946703</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="http://theblogaboutsap.blogspot.com/2007/04/step-by-step-approach-to-ceate-simple.html" target="test_blank"&gt;http://theblogaboutsap.blogspot.com/2007/04/step-by-step-approach-to-ceate-simple.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;read this &lt;/P&gt;&lt;P&gt;hope it will help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jun 2008 06:32:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963176#M946703</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-10T06:32:13Z</dc:date>
    </item>
    <item>
      <title>Re: BDC call session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963177#M946704</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi , &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First do the recording for Va01 using the TCODE : SHDB and other transactions and put the code in the program &lt;/P&gt;&lt;P&gt;Next create an internal table for the fields u recorded&lt;/P&gt;&lt;P&gt;Then assignt the fields to the bdc structure &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use the fn moduels&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;bdc_open_group&lt;/P&gt;&lt;P&gt;bdc_insert &lt;/P&gt;&lt;P&gt;bdc_clode &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for the bdc  session method . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then upload the test file from Presenatation server and see in the debug mode if all the fields are getting populated .&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Then go to sm35 and process the session and check them in both foreground and background method . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please reward if useful .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jun 2008 06:33:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963177#M946704</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-10T06:33:21Z</dc:date>
    </item>
    <item>
      <title>Re: BDC call session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963178#M946705</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rahul,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       First you go to 'SHDB' Tcode. Give a Transanction name VA01,step by step give a data into VA01.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;            SHDB transaction display on all steps,you can use that steps implement BDC programing.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;SReddy.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jun 2008 06:34:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963178#M946705</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-10T06:34:54Z</dc:date>
    </item>
    <item>
      <title>Re: BDC call session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963179#M946706</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BDC PROGRAM STRUCTURE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; There are 5 parts in a BDC program .Each part is executed one after another.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) Selection screen is used with a parameter to input the text file of TYPE RLGRAP-FILENAME . Various function modules like KD_GET_FILENAME_ON_F4 can be used to read the file name at runtime or the filename can be defaulted by using DEAULT clause in the parameter statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2) Open the text file for input.If file fails to open (SY-SUBRC NE 0) then stop the program with a error message. &lt;/P&gt;&lt;P&gt;    OPEN DATASET filename FOR INPUT IN TEXT MODE is used to open the file.&lt;/P&gt;&lt;P&gt;3)Loop through the dataset using a loop  statement like DO .. ENDDO with an EXIT statemenyt if no next record exists.&lt;/P&gt;&lt;P&gt;and filling the work structure which will hold the data for a single transaction in each loop pass.&lt;/P&gt;&lt;P&gt;   Filling the BDC TABLE of TYPE BDCDATA in the loop for every record(equivalent to transaction) in the data set.  &lt;/P&gt;&lt;P&gt; Submit the internal table containing bdc data for each and every transaction (internal table of TYPE BDCDATA is submitted for each transaction until all the records in the dataset are read) using &lt;/P&gt;&lt;P&gt;CALL TRANSACTION 'tr' USING I_bdcdata MODE 'N' UDATE 'S' .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; DO&lt;/P&gt;&lt;P&gt;  READ DATASET file INTO W_bdcdata&lt;/P&gt;&lt;P&gt;   IF SY-SUBRC NE 0.&lt;/P&gt;&lt;P&gt;    EXIT.&lt;/P&gt;&lt;P&gt;   ENDIF.&lt;/P&gt;&lt;P&gt;  PERFORM Fill_BDCDATA                                     &lt;/P&gt;&lt;P&gt;  PERFORM Submit_BDCDATA&lt;/P&gt;&lt;P&gt; ENDDO&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4) Error handling when submission via CALL TRANSACTION fails ,either by using the internal table to be filled by the system messages which is of TYPE BDCMSGCOLS and can be specified in CALL TRANSACTION statement with the addition MESSAGES INTO .&lt;/P&gt;&lt;P&gt; Or error handling by sending the mail to a predefined recipient. &lt;/P&gt;&lt;P&gt; Or for each and every transaction that fails create a&lt;/P&gt;&lt;P&gt;single BDC SESSION by using BDC_OPEN_GROUP function module&lt;/P&gt;&lt;P&gt;and submitting the intenal bdc data table to it. &lt;/P&gt;&lt;P&gt; For each and every error a report should display them&lt;/P&gt;&lt;P&gt;all at the end of the program so that the transacton in error can be identified.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; The approach of opening a BDC SESSION is often used with an error report when an error occurs as all the transaction in error can be seen and executed in the session manager .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5)Clean up actions.&lt;/P&gt;&lt;P&gt; Here clean up actions are performed like closing the dataset with CLOSE DATASET command ,closing any error&lt;/P&gt;&lt;P&gt;session if they were created using CLOSE_GROUP function module.and displaying the report .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To fill the bdc data table we should have all the information associated with the screens used in the transaction &lt;/P&gt;&lt;P&gt;and all the fields in those screens that will be filled by the CALL TRANSACTION statement.We can use BDC SESSION RECORDER  or Transaction Recorder(Transaction SHDB) to get the information on the screens and the fields. The&lt;/P&gt;&lt;P&gt;data which is required to fill the internal table of TYPE BDCDATA is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Program Name&lt;/P&gt;&lt;P&gt;Screen Number&lt;/P&gt;&lt;P&gt;Screen Begin&lt;/P&gt;&lt;P&gt;Field Name&lt;/P&gt;&lt;P&gt;Field Value  &lt;/P&gt;&lt;P&gt;Information on Field Name and Field Type can be used to create the structure that will be used to read records from the data set .&lt;/P&gt;&lt;P&gt;While filling the Field value in BDCDATA table care should be taken for special fields like 'BDC_CURSOR',' BDC_OKCODE'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Structure of BDCDATA table&lt;/P&gt;&lt;P&gt;PROGRAM   Name of program&lt;/P&gt;&lt;P&gt;DYNPRO      Number of screen&lt;/P&gt;&lt;P&gt;DYNBEGIN   If New screen begins value ='X'&lt;/P&gt;&lt;P&gt;FNAM            Field Name&lt;/P&gt;&lt;P&gt;FVAL             Field Value &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Structure of  BDCMSGCOLL&lt;/P&gt;&lt;P&gt;MSGID          Message ID&lt;/P&gt;&lt;P&gt;MSGTYP      MessageType&lt;/P&gt;&lt;P&gt;MSGNR        Message Number&lt;/P&gt;&lt;P&gt;MSGV1         1st placeholder&lt;/P&gt;&lt;P&gt;MSGV2         2nd Place Holder&lt;/P&gt;&lt;P&gt;NSGV3         3rd Placce Holder&lt;/P&gt;&lt;P&gt;MSGV4         4th Place Holder    &lt;/P&gt;&lt;P&gt;To see all the messages stored by the system in the BDCMSGCOLS table we can use LOOP AT .ENDLOOP command. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Code to read internal table of type BDCMSGCOLS.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;TABLE T100 HAS FOLLOWING FIELDS&lt;/P&gt;&lt;P&gt;SPRSL   TYPE SPRAS (Language)&lt;/P&gt;&lt;P&gt;ARBGB  TYPE ARBGP (BUSINESS AREA)&lt;/P&gt;&lt;P&gt;MSGNR  Message number (3C) &lt;/P&gt;&lt;P&gt;TEXT       Message Text (Type 73C)&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt; LOOP AT MESSTAB.     "Int Table of TYPE BDCMSGCOLS&lt;/P&gt;&lt;P&gt;        SELECT SINGLE * FROM T100 WHERE SPRSL = MESSTAB-MSGSPRA&lt;/P&gt;&lt;P&gt;                                  AND   ARBGB = MESSTAB-MSGID&lt;/P&gt;&lt;P&gt;                                  AND   MSGNR = MESSTAB-MSGNR.&lt;/P&gt;&lt;P&gt;        IF SY-SUBRC = 0.&lt;/P&gt;&lt;P&gt;          L_MSTRING = T100-TEXT.&lt;/P&gt;&lt;P&gt;          IF L_MSTRING CS '&amp;amp;1'.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;1' WITH MESSTAB-MSGV1 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;2' WITH MESSTAB-MSGV2 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;3' WITH MESSTAB-MSGV3 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;4' WITH MESSTAB-MSGV4 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;          ELSE.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;' WITH MESSTAB-MSGV1 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;' WITH MESSTAB-MSGV2 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;' WITH MESSTAB-MSGV3 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;            REPLACE '&amp;amp;' WITH MESSTAB-MSGV4 INTO L_MSTRING.&lt;/P&gt;&lt;P&gt;          ENDIF.&lt;/P&gt;&lt;P&gt;          CONDENSE L_MSTRING.&lt;/P&gt;&lt;P&gt;          WRITE: / MESSTAB-MSGTYP, L_MSTRING(250).&lt;/P&gt;&lt;P&gt;        ELSE.&lt;/P&gt;&lt;P&gt;          WRITE: / MESSTAB.&lt;/P&gt;&lt;P&gt;        ENDIF.&lt;/P&gt;&lt;P&gt;      ENDLOOP.&lt;/P&gt;&lt;P&gt;      SKIP.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt; hope this may be helpful,.............&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;praveena.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jun 2008 06:38:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bdc-call-session/m-p/3963179#M946706</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-10T06:38:28Z</dc:date>
    </item>
  </channel>
</rss>

