<?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: GET &amp; Open Cursor in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-open-cursor/m-p/909719#M56811</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;GET&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Event keyword that defines event blocks for reporting events. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Syntax&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;GET &amp;lt;node&amp;gt; [FIELDS &amp;lt;f1&amp;gt; &amp;lt;f 2&amp;gt;...].&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Only occurs in executable programs. When the logical database has passed a line of the node &amp;lt;node&amp;gt; to the program, the runtime environment triggers the GET event, and the corresponding event block is executed. The FIELDS addition allows you to specify explicitly the columns of the node that the logical database should retrieve. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLOSE CURSOR&lt;/P&gt;&lt;P&gt;Closes a database cursor. &lt;/P&gt;&lt;P&gt;Syntax&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;CLOSE CURSOR&amp;lt;/b&amp;gt; &amp;lt;c&amp;gt;.&lt;/P&gt;&lt;P&gt;Closes a cursor opened using the OPEN CURSOR statement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OPEN CURSOR&lt;/P&gt;&lt;P&gt;Opens a database cursor. &lt;/P&gt;&lt;P&gt;Syntax&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;OPEN CURSOR&amp;lt;/b&amp;gt; [WITH HOLD] &amp;lt;c&amp;gt; FOR SELECT      &amp;lt;result&amp;gt; &lt;/P&gt;&lt;P&gt;                                  FROM      &amp;lt;source&amp;gt; &lt;/P&gt;&lt;P&gt;                                  [WHERE    &amp;lt;condition&amp;gt;]&lt;/P&gt;&lt;P&gt;                                  [GROUP BY &amp;lt;fields&amp;gt;] &lt;/P&gt;&lt;P&gt;                                  [HAVING   &amp;lt;cond&amp;gt;]&lt;/P&gt;&lt;P&gt;                                  [ORDER BY &amp;lt;fields&amp;gt;].&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Opens a cursor &amp;lt;c&amp;gt; with type CURSOR for a SELECT statement. All of the clauses of the SELECT statement apart from the INTO clause can be used. The INTO clause is set in the FETCH statement. If you use the WITH HOLD addition, the cursor is not closed when a database commit occurs.&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="102201"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Judith.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 30 May 2005 10:13:39 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2005-05-30T10:13:39Z</dc:date>
    <item>
      <title>GET &amp; Open Cursor</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-open-cursor/m-p/909717#M56809</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt; Currently i am using LDBs KDF and following is the code :&lt;/P&gt;&lt;P&gt;   OPEN CURSOR WITH HOLD DB_CURSOR FOR   &amp;lt;----&lt;/P&gt;&lt;HR originaltext="---------" /&gt;&lt;P&gt;GET BKPF FIELDS&lt;/P&gt;&lt;P&gt;              BUKRS                "Company code&lt;/P&gt;&lt;P&gt;              BELNR                "Document No.&lt;/P&gt;&lt;P&gt;              GJAHR                "FY&lt;/P&gt;&lt;P&gt;              BLDAT                "DocumentDate&lt;/P&gt;&lt;P&gt;              BUDAT                "PostingDate&lt;/P&gt;&lt;P&gt;              MONAT                "FiscalPeriod&lt;/P&gt;&lt;P&gt;              XBLNR.               "Reference Document No.&lt;/P&gt;&lt;P&gt;CHECK ( BKPF-MONAT IN S_MONAT AND BKPF-BLDAT IN S_BLDAT ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   DO.&lt;/P&gt;&lt;P&gt;     FETCH  NEXT CURSOR DB_CURSOR&lt;/P&gt;&lt;P&gt;     APPENDING TABLE T_BKPF PACKAGE SIZE 10000.&lt;/P&gt;&lt;P&gt;     IF SY-SUBRC NE 0.&lt;/P&gt;&lt;P&gt;       CLOSE CURSOR DB_CURSOR.&lt;/P&gt;&lt;P&gt;       EXIT.&lt;/P&gt;&lt;P&gt;     ENDIF.&lt;/P&gt;&lt;P&gt;   ENDDO.&lt;/P&gt;&lt;P&gt;   COMMIT WORK.&lt;/P&gt;&lt;P&gt;I receive the message that SELECT is required for OPEN CURSOR. &lt;/P&gt;&lt;P&gt;I cannot use the SELECT as for Accessing the Archived data LDB had to be used and GET statements are used.&lt;/P&gt;&lt;P&gt;Can you please correct/propose new code for the above.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Thankyou,&lt;/P&gt;&lt;P&gt; - PSK&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 May 2005 09:41:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/get-open-cursor/m-p/909717#M56809</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-05-30T09:41:20Z</dc:date>
    </item>
    <item>
      <title>Re: GET &amp; Open Cursor</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-open-cursor/m-p/909718#M56810</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;Check this link.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9b5e35c111d1829f0000e829fbfe/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9b5e35c111d1829f0000e829fbfe/content.htm&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 May 2005 09:58:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/get-open-cursor/m-p/909718#M56810</guid>
      <dc:creator>jayanthi_jayaraman</dc:creator>
      <dc:date>2005-05-30T09:58:53Z</dc:date>
    </item>
    <item>
      <title>Re: GET &amp; Open Cursor</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-open-cursor/m-p/909719#M56811</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;GET&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Event keyword that defines event blocks for reporting events. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Syntax&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;GET &amp;lt;node&amp;gt; [FIELDS &amp;lt;f1&amp;gt; &amp;lt;f 2&amp;gt;...].&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Only occurs in executable programs. When the logical database has passed a line of the node &amp;lt;node&amp;gt; to the program, the runtime environment triggers the GET event, and the corresponding event block is executed. The FIELDS addition allows you to specify explicitly the columns of the node that the logical database should retrieve. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLOSE CURSOR&lt;/P&gt;&lt;P&gt;Closes a database cursor. &lt;/P&gt;&lt;P&gt;Syntax&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;CLOSE CURSOR&amp;lt;/b&amp;gt; &amp;lt;c&amp;gt;.&lt;/P&gt;&lt;P&gt;Closes a cursor opened using the OPEN CURSOR statement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OPEN CURSOR&lt;/P&gt;&lt;P&gt;Opens a database cursor. &lt;/P&gt;&lt;P&gt;Syntax&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;OPEN CURSOR&amp;lt;/b&amp;gt; [WITH HOLD] &amp;lt;c&amp;gt; FOR SELECT      &amp;lt;result&amp;gt; &lt;/P&gt;&lt;P&gt;                                  FROM      &amp;lt;source&amp;gt; &lt;/P&gt;&lt;P&gt;                                  [WHERE    &amp;lt;condition&amp;gt;]&lt;/P&gt;&lt;P&gt;                                  [GROUP BY &amp;lt;fields&amp;gt;] &lt;/P&gt;&lt;P&gt;                                  [HAVING   &amp;lt;cond&amp;gt;]&lt;/P&gt;&lt;P&gt;                                  [ORDER BY &amp;lt;fields&amp;gt;].&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Opens a cursor &amp;lt;c&amp;gt; with type CURSOR for a SELECT statement. All of the clauses of the SELECT statement apart from the INTO clause can be used. The INTO clause is set in the FETCH statement. If you use the WITH HOLD addition, the cursor is not closed when a database commit occurs.&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="102201"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Judith.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 May 2005 10:13:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/get-open-cursor/m-p/909719#M56811</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-05-30T10:13:39Z</dc:date>
    </item>
  </channel>
</rss>

