<?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: Handling errors in Function module in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109742#M738315</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gurus ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;     When i try to use gui_download in my extractor , my code is going for a dump .&lt;/P&gt;&lt;P&gt;I cant find whts the actual problem .&lt;/P&gt;&lt;P&gt;kindly advice me on the same .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An exception occurred that is explained in detail below.&lt;/P&gt;&lt;P&gt;The exception, which is assigned to class 'CX_SY_OPEN_SQL_DB', was not caught&lt;/P&gt;&lt;P&gt; in&lt;/P&gt;&lt;P&gt;procedure "Z01_FBIWI_AR_EXTRACTOR" "(FUNCTION)", nor was it propagated by a&lt;/P&gt;&lt;P&gt; RAISING clause.&lt;/P&gt;&lt;P&gt;Since the caller of the procedure could not have anticipated that the&lt;/P&gt;&lt;P&gt;exception would occur, the current program is terminated.&lt;/P&gt;&lt;P&gt;The reason for the exception is:&lt;/P&gt;&lt;P&gt;One of the database selections included a database Commit.&lt;/P&gt;&lt;P&gt;The selection was then supposed to continue. Before a&lt;/P&gt;&lt;P&gt;database commit, however, all outstanding database selections&lt;/P&gt;&lt;P&gt;must be concluded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Possible causes in the application program:&lt;/P&gt;&lt;P&gt;While a read process from a database cursor is taking place&lt;/P&gt;&lt;P&gt;(within a loop SELECT/LOOP/EXEC SQL or before a FETCH command),&lt;/P&gt;&lt;P&gt;one of the following statements is used:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- MESSAGE (apart from MESSAGE S...)&lt;/P&gt;&lt;P&gt;- COMMIT WORK&lt;/P&gt;&lt;P&gt;- ROLLBACK WORK&lt;/P&gt;&lt;P&gt;- BREAK-POINT&lt;/P&gt;&lt;P&gt;- WAIT&lt;/P&gt;&lt;P&gt;- CALL FUNCTION ... DESTINATION (synchronous RFC)&lt;/P&gt;&lt;P&gt;- CALL FUNCTION ... STARTING NEW TASK&lt;/P&gt;&lt;P&gt; RECEIVE RESULTS&lt;/P&gt;&lt;P&gt; CALL DIALOG&lt;/P&gt;&lt;P&gt; CALL SELECTION-SCREEN&lt;/P&gt;&lt;P&gt; CALL TRANSACTION&lt;/P&gt;&lt;P&gt; CALL SCREEN, or any other statement that results in the display of a&lt;/P&gt;&lt;P&gt; new screen&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;henever a program runs in debugging mode, a "COMMIT WORK" can&lt;/P&gt;&lt;P&gt;ossibly be triggered during database selection. This abnormal&lt;/P&gt;&lt;P&gt;ermination can also occur in debugging mode even with a correct&lt;/P&gt;&lt;P&gt;rogram.&lt;/P&gt;&lt;P&gt; "COMMIT WORK" during debugging may be due to the following reasons:&lt;/P&gt;&lt;P&gt;. A program or screen was regenerated during debugging&lt;/P&gt;&lt;P&gt;  and updated in the database.&lt;/P&gt;&lt;P&gt;. Each user needs a separate process in debugging mode, but&lt;/P&gt;&lt;P&gt;  the number of available processes is restricted. If this&lt;/P&gt;&lt;P&gt;  limit is exceeded, each debugging step then requires a&lt;/P&gt;&lt;P&gt;  "COMMIT WORK".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;he error occurs in a statement in which the table "BSAD " is accessed.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 28 Nov 2007 09:38:18 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-11-28T09:38:18Z</dc:date>
    <item>
      <title>Handling errors in Function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109739#M738312</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gurus ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      I need some clarification in a function module . i need to handle errors in a function module .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;iam writing an extractor for open item (ie using  table bsid ,ztable ) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in some scenarios ,  some records of bsid are not matching ztable entries .&lt;/P&gt;&lt;P&gt;just i want to capture that records and write it to a flat file .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can any one help me out on this how to do it .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks ,&lt;/P&gt;&lt;P&gt;Shankar.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Nov 2007 07:02:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109739#M738312</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-28T07:02:12Z</dc:date>
    </item>
    <item>
      <title>Re: Handling errors in Function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109740#M738313</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Gurus ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;     Do we have any return paramenters in a function module like we are having a BAPI .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kindly clarify .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shankar .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Nov 2007 07:07:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109740#M738313</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-28T07:07:32Z</dc:date>
    </item>
    <item>
      <title>Re: Handling errors in Function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109741#M738314</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;  Refer this code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*--Call function to download the error file&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'GUI_DOWNLOAD'&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      filename         = file&lt;/P&gt;&lt;P&gt;      filetype         = 'ASC'&lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      data_tab         = pr_eord_error&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;      file_write_error = 1&lt;/P&gt;&lt;P&gt;      no_authority     = 5&lt;/P&gt;&lt;P&gt;      unknown_error    = 6&lt;/P&gt;&lt;P&gt;      access_denied    = 15&lt;/P&gt;&lt;P&gt;      file_not_found   = 19.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CASE  sy-subrc .&lt;/P&gt;&lt;P&gt;    WHEN '1'.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; Unable to write the error file.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      MESSAGE e505.&lt;/P&gt;&lt;P&gt;    WHEN '2'.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; No authority to write the file.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      MESSAGE e506.&lt;/P&gt;&lt;P&gt;    WHEN '3'.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; Access Denied.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      MESSAGE e507.&lt;/P&gt;&lt;P&gt;    WHEN '4'.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; File not Found.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      MESSAGE e503.&lt;/P&gt;&lt;P&gt;  ENDCASE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Prashant&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Nov 2007 07:10:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109741#M738314</guid>
      <dc:creator>former_member386202</dc:creator>
      <dc:date>2007-11-28T07:10:58Z</dc:date>
    </item>
    <item>
      <title>Re: Handling errors in Function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109742#M738315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gurus ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;     When i try to use gui_download in my extractor , my code is going for a dump .&lt;/P&gt;&lt;P&gt;I cant find whts the actual problem .&lt;/P&gt;&lt;P&gt;kindly advice me on the same .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An exception occurred that is explained in detail below.&lt;/P&gt;&lt;P&gt;The exception, which is assigned to class 'CX_SY_OPEN_SQL_DB', was not caught&lt;/P&gt;&lt;P&gt; in&lt;/P&gt;&lt;P&gt;procedure "Z01_FBIWI_AR_EXTRACTOR" "(FUNCTION)", nor was it propagated by a&lt;/P&gt;&lt;P&gt; RAISING clause.&lt;/P&gt;&lt;P&gt;Since the caller of the procedure could not have anticipated that the&lt;/P&gt;&lt;P&gt;exception would occur, the current program is terminated.&lt;/P&gt;&lt;P&gt;The reason for the exception is:&lt;/P&gt;&lt;P&gt;One of the database selections included a database Commit.&lt;/P&gt;&lt;P&gt;The selection was then supposed to continue. Before a&lt;/P&gt;&lt;P&gt;database commit, however, all outstanding database selections&lt;/P&gt;&lt;P&gt;must be concluded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Possible causes in the application program:&lt;/P&gt;&lt;P&gt;While a read process from a database cursor is taking place&lt;/P&gt;&lt;P&gt;(within a loop SELECT/LOOP/EXEC SQL or before a FETCH command),&lt;/P&gt;&lt;P&gt;one of the following statements is used:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- MESSAGE (apart from MESSAGE S...)&lt;/P&gt;&lt;P&gt;- COMMIT WORK&lt;/P&gt;&lt;P&gt;- ROLLBACK WORK&lt;/P&gt;&lt;P&gt;- BREAK-POINT&lt;/P&gt;&lt;P&gt;- WAIT&lt;/P&gt;&lt;P&gt;- CALL FUNCTION ... DESTINATION (synchronous RFC)&lt;/P&gt;&lt;P&gt;- CALL FUNCTION ... STARTING NEW TASK&lt;/P&gt;&lt;P&gt; RECEIVE RESULTS&lt;/P&gt;&lt;P&gt; CALL DIALOG&lt;/P&gt;&lt;P&gt; CALL SELECTION-SCREEN&lt;/P&gt;&lt;P&gt; CALL TRANSACTION&lt;/P&gt;&lt;P&gt; CALL SCREEN, or any other statement that results in the display of a&lt;/P&gt;&lt;P&gt; new screen&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;henever a program runs in debugging mode, a "COMMIT WORK" can&lt;/P&gt;&lt;P&gt;ossibly be triggered during database selection. This abnormal&lt;/P&gt;&lt;P&gt;ermination can also occur in debugging mode even with a correct&lt;/P&gt;&lt;P&gt;rogram.&lt;/P&gt;&lt;P&gt; "COMMIT WORK" during debugging may be due to the following reasons:&lt;/P&gt;&lt;P&gt;. A program or screen was regenerated during debugging&lt;/P&gt;&lt;P&gt;  and updated in the database.&lt;/P&gt;&lt;P&gt;. Each user needs a separate process in debugging mode, but&lt;/P&gt;&lt;P&gt;  the number of available processes is restricted. If this&lt;/P&gt;&lt;P&gt;  limit is exceeded, each debugging step then requires a&lt;/P&gt;&lt;P&gt;  "COMMIT WORK".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;he error occurs in a statement in which the table "BSAD " is accessed.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Nov 2007 09:38:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/handling-errors-in-function-module/m-p/3109742#M738315</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-28T09:38:18Z</dc:date>
    </item>
  </channel>
</rss>

