<?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: Validating the data given in the excel file in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175100#M998146</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;At first upload the excel file to your ABAP program there data will be in the internal table formate.&lt;/P&gt;&lt;P&gt;Validate the data and update the valid records in your custome table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Bikas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 16 Jul 2008 05:29:18 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-07-16T05:29:18Z</dc:date>
    <item>
      <title>Validating the data given in the excel file</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175099#M998145</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;I need to upload the ztable with the data given in the excel file.But before uploading I need to do some validation on the fields given in the file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example the first field in the file is plant.I need to check whether the value given for the plant in the file exists in T001W table(check table) or not.Similarly for other fields I need to check with the check tables corresponding to them.If the value doesn't exist in the table then it should give a load error as 'Value &amp;amp;&amp;amp;&amp;amp;&amp;amp; not valid for "field".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anyone tell me how can I do this validation?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Jul 2008 05:23:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175099#M998145</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-16T05:23:08Z</dc:date>
    </item>
    <item>
      <title>Re: Validating the data given in the excel file</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175100#M998146</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;At first upload the excel file to your ABAP program there data will be in the internal table formate.&lt;/P&gt;&lt;P&gt;Validate the data and update the valid records in your custome table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Bikas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Jul 2008 05:29:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175100#M998146</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-16T05:29:18Z</dc:date>
    </item>
    <item>
      <title>Re: Validating the data given in the excel file</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175101#M998147</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;Fetch the data into internal table using gui_upload.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then fetch the data from T001W into an internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then to check for your plants, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT itab_t001w.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; READ TABLE itab_data  INTO wa_data WITH KEY werks = wa_t001w-werks.&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;Proceed like above, itab_data is the internal table where you uplaod your excel data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if Helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Prosenjit.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Jul 2008 05:36:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175101#M998147</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-16T05:36:10Z</dc:date>
    </item>
    <item>
      <title>Re: Validating the data given in the excel file</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175102#M998148</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi upload data from flat file by using FM   GUI_UPLOAD.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT itab.&lt;/P&gt;&lt;P&gt;SELECT SINGLE werks FROM t001w INTO t001w-werks &lt;/P&gt;&lt;P&gt;                                    WHERE werks = itab-werks.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC NE 0.&lt;/P&gt;&lt;P&gt;it_error-field = 'value&amp;amp; field description not available.&lt;/P&gt;&lt;P&gt;APPEND it_error.&lt;/P&gt;&lt;P&gt;CONTINUE.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then 2nd field check with mapping table...&lt;/P&gt;&lt;P&gt;then 3rd field check with mapping table...&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;/P&gt;&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;P&gt;ENDLOOP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Jul 2008 05:48:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175102#M998148</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-16T05:48:38Z</dc:date>
    </item>
    <item>
      <title>Re: Validating the data given in the excel file</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175103#M998149</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;you need to dowload the data from your flat file to a internal table first. For that you can use FM ' WS_UPLOAD' .&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;here is a small demo for it,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'WS_UPLOAD'&lt;/P&gt;&lt;P&gt; EXPORTING&lt;/P&gt;&lt;P&gt;   FILENAME                      = 'C:\abcd.TXT'&lt;/P&gt;&lt;P&gt;   FILETYPE                      = 'ASC'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  TABLES&lt;/P&gt;&lt;P&gt;    data_tab                      = itab&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now once you have data in a internal table you can do validations on it in LOOP...........ENDLOOP statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Jul 2008 05:51:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/validating-the-data-given-in-the-excel-file/m-p/4175103#M998149</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-16T05:51:21Z</dc:date>
    </item>
  </channel>
</rss>

