<?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: Updating Z-table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824516#M919750</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;The 2 internal tables don't seem to have a similar structure .  Please check how you are comparing .  And the fields you are comparing have similar domain ?  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Deepthi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 14 May 2008 11:47:30 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-05-14T11:47:30Z</dc:date>
    <item>
      <title>Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824514#M919748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good Moring,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My task is to update a custom Z-table with respect to the given flatfile. First, I have to upload the flatfile data and then compare &amp;amp; update the Z-table on the basis of the common record.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To do the above task, I have created one internal table for the flatfile data and one more internal table for the Z-table data. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First, I want to compare the both internal tables for the common records, and then, modify the Z-table from the internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now, I have written the code for comparing the internal tables,&lt;/P&gt;&lt;P&gt;even though there are common records (checked in the debugging mode using the tables option) this Sy-Subrc = 4 always showing 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Plesas, give me some use ful hint, I am pasting the code below.........&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT ZPPBLORD.&lt;/P&gt;&lt;P&gt;*Tables&lt;/P&gt;&lt;P&gt;TABLES: ZBCTBLORDK, " Blend Orders For Honeywell blending in BCT&lt;/P&gt;&lt;P&gt;        ZBCTSTATUS. " BCT - Status code table for blend orders&lt;/P&gt;&lt;P&gt;*Internal Tables&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF IT_DBTAB OCCURS 0,&lt;/P&gt;&lt;P&gt;      AUFNR(12), " like zbctblordk-aufnr,&lt;/P&gt;&lt;P&gt;      SMARTCRDID(12), " like zbctblordk-smartcrdid,&lt;/P&gt;&lt;P&gt;      AEDAT(10), " like zbctblordk-aedat,&lt;/P&gt;&lt;P&gt;      AEUHR(8), " like zbctblordk-aeuhr,&lt;/P&gt;&lt;P&gt;      STATUS LIKE ZBCTBLORDK-STATUS,&lt;/P&gt;&lt;P&gt;      END OF IT_DBTAB.&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF IT_FLFILE OCCURS 0,&lt;/P&gt;&lt;P&gt;      AUFNR(12), " like zbctblordk-aufnr,&lt;/P&gt;&lt;P&gt;      SMARTCRDID(12), " like zbctblordk-smartcrdid,&lt;/P&gt;&lt;P&gt;      AEDAT(10), " like zbctblordk-aedat,&lt;/P&gt;&lt;P&gt;      AEUHR(8), " like zbctblordk-aeuhr,&lt;/P&gt;&lt;P&gt;      STAT_CODE LIKE ZBCTSTATUS-STAT_CODE,&lt;/P&gt;&lt;P&gt;      STAT_TEXT LIKE ZBCTSTATUS-STAT_TEXT,&lt;/P&gt;&lt;P&gt;      END OF IT_FLFILE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; START-OF-SELECTION.&lt;/P&gt;&lt;P&gt; SELECT AUFNR&lt;/P&gt;&lt;P&gt;        SMARTCRDID&lt;/P&gt;&lt;P&gt;        AEDAT&lt;/P&gt;&lt;P&gt;        AEUHR&lt;/P&gt;&lt;P&gt;        STATUS FROM ZBCTBLORDK INTO TABLE IT_DBTAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Upload data from the specified file to internal table&lt;/P&gt;&lt;P&gt;    CALL FUNCTION 'WS_UPLOAD'&lt;/P&gt;&lt;P&gt;         EXPORTING&lt;/P&gt;&lt;P&gt;              FILENAME            = 'P:\ZBCT.TXT'&lt;/P&gt;&lt;P&gt;              FILETYPE            = 'DAT'&lt;/P&gt;&lt;P&gt;         TABLES&lt;/P&gt;&lt;P&gt;              DATA_TAB            = IT_FLFILE&lt;/P&gt;&lt;P&gt;         EXCEPTIONS&lt;/P&gt;&lt;P&gt;              CONVERSION_ERROR    = 1&lt;/P&gt;&lt;P&gt;              FILE_OPEN_ERROR     = 2&lt;/P&gt;&lt;P&gt;              FILE_READ_ERROR     = 3&lt;/P&gt;&lt;P&gt;              INVALID_TABLE_WIDTH = 4&lt;/P&gt;&lt;P&gt;              INVALID_TYPE        = 5&lt;/P&gt;&lt;P&gt;              NO_BATCH            = 6&lt;/P&gt;&lt;P&gt;              UNKNOWN_ERROR       = 7&lt;/P&gt;&lt;P&gt;              OTHERS              = 8.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; END-OF-SELECTION.&lt;/P&gt;&lt;P&gt; CLEAR: IT_FLFILE, IT_DBTAB.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;BREAK-POINT.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;        LOOP AT IT_DBTAB.&lt;/P&gt;&lt;P&gt;       &lt;STRONG&gt;READ TABLE IT_FLFILE WITH KEY AUFNR = IT_DBTAB-AUFNR&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;       &lt;STRONG&gt;SMARTCRDID = IT_DBTAB-SMARTCRDID.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;       &lt;STRONG&gt;IF SY-SUBRC = 0.&lt;/STRONG&gt;* SY-SUBRC always showing 4, and getting in-side&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;I want to use Modify internal table command here&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;WRITE:/ IT_DBTAB-AUFNR,&lt;/P&gt;&lt;P&gt;        IT_DBTAB-SMARTCRDID,&lt;/P&gt;&lt;P&gt;        IT_DBTAB-AEDAT,&lt;/P&gt;&lt;P&gt;        IT_DBTAB-AEUHR,&lt;/P&gt;&lt;P&gt;        IT_DBTAB-STATUS.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;        ENDLOOP.&lt;/P&gt;&lt;P&gt;        ENDLOOP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 11:35:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824514#M919748</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T11:35:08Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824515#M919749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;1.First upload the records from flat file to Internal table.&lt;/P&gt;&lt;P&gt;2.Then INSERT/MODIFY the records into the Ztable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check:&lt;/P&gt;&lt;P&gt;REPORT zmat_no message-id zebg.&lt;/P&gt;&lt;P&gt;TYPE-POOLS truxs.&lt;/P&gt;&lt;P&gt;TABLES:zmatnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA : itab LIKE alsmex_tabline OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA row LIKE alsmex_tabline-row.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : g_matnr like mara-matnr.&lt;/P&gt;&lt;P&gt;data : count type i.&lt;/P&gt;&lt;P&gt;data : itab_count type i.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : gi_final like zmatnr occurs 0 with header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*data : begin of gi_final occurs 0,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mat_old like mara-matnr, &lt;/P&gt;&lt;P&gt;mat_new like mara-matnr, &lt;/P&gt;&lt;P&gt;end of gi_final. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;***********************&lt;STRONG&gt;Selection Screen&lt;/STRONG&gt;*************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.&lt;/P&gt;&lt;P&gt;PARAMETER : pfname LIKE rlgrap-filename OBLIGATORY.&lt;/P&gt;&lt;P&gt;select-options : records for count.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN END OF BLOCK b1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*******************************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*********************&lt;STRONG&gt;At Selection Screen&lt;/STRONG&gt;*************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN ON VALUE-REQUEST FOR pfname.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PERFORM search.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*******************************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;perform process.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;form process.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;filename = pfname&lt;/P&gt;&lt;P&gt;i_begin_col = 1&lt;/P&gt;&lt;P&gt;i_begin_row = 2&lt;/P&gt;&lt;P&gt;i_end_col = 12&lt;/P&gt;&lt;P&gt;i_end_row = 65000&lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;intern = itab&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;inconsistent_parameters = 1&lt;/P&gt;&lt;P&gt;upload_ole = 2&lt;/P&gt;&lt;P&gt;OTHERS = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF sy-subrc 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;describe table itab lines itab_count.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;row = 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if itab-row row.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;append gi_final.&lt;/P&gt;&lt;P&gt;clear gi_final.&lt;/P&gt;&lt;P&gt;&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;&lt;/P&gt;&lt;P&gt;case itab-col.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when '1'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR G_MATNR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gi_final-OLD_MATNR = itab-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CONCATENATE 'NEW' gi_final-old_matnr INTO itab-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gi_final-new_MATNR = itab-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endcase.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;row = itab-row.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;append gi_final.&lt;/P&gt;&lt;P&gt;clear gi_final.&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;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'PROGRESS_INDICATOR' &lt;/P&gt;&lt;P&gt;EXPORTING &lt;/P&gt;&lt;P&gt;I_TEXT = 'File Has Been Successfully Uploaded from Workstation ' . &lt;/P&gt;&lt;P&gt;if not gi_final[] is initial.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if not records-low is initial .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if not records-high is initial.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;records-high = records-high + 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DESCRIBE TABLE gi_final LINES count.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF records-high &amp;lt; count.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DELETE gi_final FROM records-high TO count.&lt;/P&gt;&lt;P&gt;&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;IF records-low &amp;lt;&amp;gt; 1.&lt;/P&gt;&lt;P&gt;IF records-low 0.&lt;/P&gt;&lt;P&gt;DELETE gi_final FROM 1 TO records-low.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&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;IF NOT GI_FINAL[] IS INITIAL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'PROGRESS_INDICATOR'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;I_TEXT = 'Processing zmatnr table'&lt;/P&gt;&lt;P&gt;I_OUTPUT_IMMEDIATELY = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if itab_count count. &lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;message i000 with 'records are not matching'. &lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;exit. &lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;else. &lt;/P&gt;&lt;P&gt;modify zmatnr from table gi_final.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;message i000 with 'data base table modified successfully'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;endif.&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;&amp;amp;----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;*&amp;amp; Form search&lt;/P&gt;&lt;P&gt;&amp;amp;----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;text&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="-------------------------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--&amp;gt; p1 text &lt;/P&gt;&lt;P&gt;&amp;lt;-- p2 text&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="-------------------------------------------------------------------------------" /&gt;&lt;P&gt; FORM search .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'KD_GET_FILENAME_ON_F4'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;static = 'X'&lt;/P&gt;&lt;P&gt;CHANGING&lt;/P&gt;&lt;P&gt;file_name = pfname.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM. " search&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Shiva.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 11:44:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824515#M919749</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T11:44:45Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824516#M919750</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;The 2 internal tables don't seem to have a similar structure .  Please check how you are comparing .  And the fields you are comparing have similar domain ?  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Deepthi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 11:47:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824516#M919750</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T11:47:30Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824517#M919751</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;Does the IT_FLFILE-AUFNR have leading zeros?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WS_UPLOAD or GUI_UPLOAD.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT AUFNR&lt;/P&gt;&lt;P&gt;SMARTCRDID&lt;/P&gt;&lt;P&gt;AEDAT&lt;/P&gt;&lt;P&gt;AEUHR&lt;/P&gt;&lt;P&gt;STATUS FROM ZBCTBLORDK INTO TABLE IT_DBTAB&lt;/P&gt;&lt;P&gt;for all entries in it_flfile&lt;/P&gt;&lt;P&gt;where AUFNR = IT_flfile-AUFNR&lt;/P&gt;&lt;P&gt;SMARTCRDID = IT_flfile-SMARTCRDID.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort it_dbtab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at it_flfile.&lt;/P&gt;&lt;P&gt;read table it_dbtab with key AUFNR = IT_flfile-AUFNR&lt;/P&gt;&lt;P&gt;SMARTCRDID = IT_flfile-SMARTCRDID.&lt;/P&gt;&lt;P&gt;if sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;  delete it_flfile.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;endllop.&lt;/P&gt;&lt;P&gt;update table ZBCTBLORDK from it_flfile.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;...Reward if useful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 11:50:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824517#M919751</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T11:50:04Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824518#M919752</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;Is your problem solved with the above given solution...&lt;/P&gt;&lt;P&gt;or else just message back...&lt;/P&gt;&lt;P&gt;i have done a similar requirement..i can help you...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers..,&lt;/P&gt;&lt;P&gt;Trinath.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 12:13:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824518#M919752</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T12:13:44Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824519#M919753</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 Debugging, check the values populated in IT_DBTAB-AUFNR and IT_DBTAB-SMARTCRDID.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If leading zeros are not added, then use this Function Module to add leading zeros.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function 'CONVERSION_EXIT_ALPHA_INPUT'&lt;/P&gt;&lt;P&gt;      exporting&lt;/P&gt;&lt;P&gt;        input  = it_dbtab-aufnr.&lt;/P&gt;&lt;P&gt;      importing&lt;/P&gt;&lt;P&gt;        output = it_dbtab-aufnr.&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;Sandeep Reddy.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 12:16:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824519#M919753</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T12:16:30Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824520#M919754</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for quick response.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Trinath, I have just tried with the I Wong's solution, still the IT_DBTAB is not populating with the records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please, send your solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;KalChand&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 12:24:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824520#M919754</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T12:24:10Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824521#M919755</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sudeep,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have found in the debugging that IT_DBTAB got populated with the records, &lt;/P&gt;&lt;P&gt;But while modifying, it's giving error (SY-SUBRC = 4).&lt;/P&gt;&lt;P&gt;there are no leading zeros......&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;KC&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 12:27:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824521#M919755</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T12:27:54Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824522#M919756</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;This is not the conventional way of storing the data into an internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First of all you have to SPLIT IT_FLFILE and store in a structured Internal table. And then READ.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Otherwise in the debug mode, make sure the values are stored into correspoding fields of IT_FLFILE. Sometimes It will be messed up.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 13:02:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824522#M919756</guid>
      <dc:creator>asik_shameem</dc:creator>
      <dc:date>2008-05-14T13:02:52Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Z-table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824523#M919757</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I got problem because of "LEADING ZEROS" as sudeep said.&lt;/P&gt;&lt;P&gt;It's solved now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help,&lt;/P&gt;&lt;P&gt;KC&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2008 16:00:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-z-table/m-p/3824523#M919757</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-14T16:00:35Z</dc:date>
    </item>
  </channel>
</rss>

