<?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: Processing session in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463985#M1251626</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi JOhn.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See the sample code how to create BDC session in FUnction Module..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

* Do the Call transaction recording..

CALL TRANSACTION 'ME22'
             USING bdc_tab
              MODE w_lmode
              UPDATE 'S'
          MESSAGES INTO message_tab.

* Error handling
  READ TABLE message_tab WITH KEY msgtyp = 'E'.
  IF sy-subrc EQ 0.

    CONCATENATE 'GM' sy-datum sy-uzeit INTO group.
    MOVE 'ME22' TO tcode.

* Opening BDC session and creating session..
    CALL FUNCTION 'BDC_OPEN_GROUP'
      EXPORTING
        client   = sy-mandt
        group    = group
        user     = sy-uname
        keep     = keep
        holddate = holddate.
 
    CALL FUNCTION 'BDC_INSERT'
      EXPORTING
        tcode     = tcode
      TABLES
        dynprotab = bdc_tab.
 
    CALL FUNCTION 'BDC_CLOSE_GROUP'.
ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reagrds,&lt;/P&gt;&lt;P&gt;Prabhudas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Apr 2009 11:45:41 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-04-15T11:45:41Z</dc:date>
    <item>
      <title>Processing session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463982#M1251623</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;whether is is  possible to process a session created with function module bdc_open_group without closing it using function module bdc_close_group, in BDC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Mani&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Apr 2009 11:23:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463982#M1251623</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-15T11:23:53Z</dc:date>
    </item>
    <item>
      <title>Re: Processing session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463983#M1251624</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;The session will be created without bdc_close_group but it will be in status "Creating". You select the session and press the Release button. Later you can process the session.&lt;/P&gt;&lt;P&gt;best practice is to use bdc_close_group.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Hakim&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Abdul Hakim on Apr 15, 2009 7:36 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Apr 2009 11:24:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463983#M1251624</guid>
      <dc:creator>abdul_hakim</dc:creator>
      <dc:date>2009-04-15T11:24:51Z</dc:date>
    </item>
    <item>
      <title>Re: Processing session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463984#M1251625</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi John,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

you can process a session in function module ..

wait 5 min i had coded for one program i will send the sample code.. how to create a session in Function module..
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Prabhudas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Apr 2009 11:30:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463984#M1251625</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-15T11:30:00Z</dc:date>
    </item>
    <item>
      <title>Re: Processing session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463985#M1251626</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi JOhn.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See the sample code how to create BDC session in FUnction Module..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

* Do the Call transaction recording..

CALL TRANSACTION 'ME22'
             USING bdc_tab
              MODE w_lmode
              UPDATE 'S'
          MESSAGES INTO message_tab.

* Error handling
  READ TABLE message_tab WITH KEY msgtyp = 'E'.
  IF sy-subrc EQ 0.

    CONCATENATE 'GM' sy-datum sy-uzeit INTO group.
    MOVE 'ME22' TO tcode.

* Opening BDC session and creating session..
    CALL FUNCTION 'BDC_OPEN_GROUP'
      EXPORTING
        client   = sy-mandt
        group    = group
        user     = sy-uname
        keep     = keep
        holddate = holddate.
 
    CALL FUNCTION 'BDC_INSERT'
      EXPORTING
        tcode     = tcode
      TABLES
        dynprotab = bdc_tab.
 
    CALL FUNCTION 'BDC_CLOSE_GROUP'.
ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reagrds,&lt;/P&gt;&lt;P&gt;Prabhudas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Apr 2009 11:45:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463985#M1251626</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-15T11:45:41Z</dc:date>
    </item>
    <item>
      <title>Re: Processing session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463986#M1251627</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;it is required to close the session once u upend...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so u need use close_group.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;~linganna&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Apr 2009 12:08:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463986#M1251627</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-15T12:08:02Z</dc:date>
    </item>
    <item>
      <title>Re: Processing session</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463987#M1251628</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;In BDC session method when you are open the session using BDC_OPEN_GROUP compulsary to close the group using BDC_CLOSE_GROUP ,if it is not closed in SM35 session in not created,we cannot process the session.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please check below code &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM BDC_BATCH_INPUT_SESSION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'BDC_OPEN_GROUP'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;              CLIENT              = SY-MANDT&lt;/P&gt;&lt;P&gt;              GROUP               = I_SESSIONNAME&lt;/P&gt;&lt;P&gt;              USER                = SY-UNAME&lt;/P&gt;&lt;P&gt;              KEEP                = 'X'&lt;/P&gt;&lt;P&gt;         EXCEPTIONS&lt;/P&gt;&lt;P&gt;              CLIENT_INVALID      = 1&lt;/P&gt;&lt;P&gt;              DESTINATION_INVALID = 2&lt;/P&gt;&lt;P&gt;              GROUP_INVALID       = 3&lt;/P&gt;&lt;P&gt;              GROUP_IS_LOCKED     = 4&lt;/P&gt;&lt;P&gt;              HOLDDATE_INVALID    = 5&lt;/P&gt;&lt;P&gt;              INTERNAL_ERROR      = 6&lt;/P&gt;&lt;P&gt;              QUEUE_ERROR         = 7&lt;/P&gt;&lt;P&gt;              RUNNING             = 8&lt;/P&gt;&lt;P&gt;              SYSTEM_LOCK_ERROR   = 9&lt;/P&gt;&lt;P&gt;              USER_INVALID        = 10&lt;/P&gt;&lt;P&gt;              OTHERS              = 11.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;BDC Insert&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;LOOP AT it_employee INTO wa_employee.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      PERFORM bdc_dynpro      USING 'SAPMP50A' '1000'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'RP50G-PERNR'&lt;/P&gt;&lt;P&gt;                                    wa_employee-pernr.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'RP50G-TIMR6'&lt;/P&gt;&lt;P&gt;                                    'X'.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'BDC_CURSOR'&lt;/P&gt;&lt;P&gt;                                    'RP50G-CHOIC'.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'RP50G-CHOIC'&lt;/P&gt;&lt;P&gt;                                    '0002'.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'BDC_OKCODE'&lt;/P&gt;&lt;P&gt;                                    '=MOD'.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_dynpro      USING 'MP000200' '2044'.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'BDC_OKCODE'&lt;/P&gt;&lt;P&gt;                                    '=UPD'.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'BDC_CURSOR'&lt;/P&gt;&lt;P&gt;                                    'P0002-RUFNM'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'P0002-BEGDA'&lt;/P&gt;&lt;P&gt;                                    wa_employee-begda.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'P0002-ENDDA'&lt;/P&gt;&lt;P&gt;                                    wa_employee-endda.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'P0002-MIDNM'&lt;/P&gt;&lt;P&gt;                                    wa_employee-midnm.&lt;/P&gt;&lt;P&gt;      PERFORM bdc_field       USING 'P0002-RUFNM'&lt;/P&gt;&lt;P&gt;                                   wa_employee-rufnm.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BDC_INSERT'&lt;/P&gt;&lt;P&gt;         EXPORTING&lt;/P&gt;&lt;P&gt;              TCODE            = 'PA30'&lt;/P&gt;&lt;P&gt;         TABLES&lt;/P&gt;&lt;P&gt;              DYNPROTAB        = it_bdcdata&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;         INTERNAL_ERROR   = 1&lt;/P&gt;&lt;P&gt;         NOT_OPEN         = 2&lt;/P&gt;&lt;P&gt;         QUEUE_ERROR      = 3&lt;/P&gt;&lt;P&gt;         TCODE_INVALID    = 4&lt;/P&gt;&lt;P&gt;         PRINTING_INVALID = 5&lt;/P&gt;&lt;P&gt;         POSTING_INVALID  = 6&lt;/P&gt;&lt;P&gt;         OTHERS           = 7.&lt;/P&gt;&lt;P&gt;clear it_bdcdata.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Closing Batch Input&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CALL FUNCTION 'BDC_CLOSE_GROUP'.&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;Regards,&lt;/P&gt;&lt;P&gt;Madhu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Apr 2009 05:09:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/processing-session/m-p/5463987#M1251628</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-16T05:09:20Z</dc:date>
    </item>
  </channel>
</rss>

