<?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: Error when passing data from app server... in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406780#M818131</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eswar,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How do I that?Thanks again!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 14 Feb 2008 03:24:23 GMT</pubDate>
    <dc:creator>aris_hidalgo</dc:creator>
    <dc:date>2008-02-14T03:24:23Z</dc:date>
    <item>
      <title>Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406778#M818129</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Experts, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am encountering an error when trying to pass data from application server&lt;/P&gt;&lt;P&gt;to my internal table. Below is the error:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"You cannot convert the character set"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope you can help me guys.Thank you and take care!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:12:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406778#M818129</guid>
      <dc:creator>aris_hidalgo</dc:creator>
      <dc:date>2008-02-14T03:12:31Z</dc:date>
    </item>
    <item>
      <title>Re: Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406779#M818130</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try using addition : &lt;STRONG&gt;IGNORING CONVERSION ERRORS&lt;/STRONG&gt; and check if you still encounter the same error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Eswar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:19:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406779#M818130</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-14T03:19:24Z</dc:date>
    </item>
    <item>
      <title>Re: Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406780#M818131</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eswar,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How do I that?Thanks again!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:24:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406780#M818131</guid>
      <dc:creator>aris_hidalgo</dc:creator>
      <dc:date>2008-02-14T03:24:23Z</dc:date>
    </item>
    <item>
      <title>Re: Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406781#M818132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Viray,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addtion is for OPEN DATASET statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt;OPEN DATASET &amp;lt;dsn&amp;gt; FOR ...&lt;/P&gt;&lt;P&gt;&amp;gt;    IGNORING CONVERSION ERRORS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check below extract from help:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
Addition 4 
... IGNORING CONVERSION ERRORS 


Effect 
This addition ensures that no exception is triggered when an error occurs during character set conversion and a file is accessed in read or write mode. If you do not use this addition, the exception CX_SY_CONVERSION_CODEPAGE is triggered when a conversion error occurs. (For details see READ DATASET and TRANSFER.) 
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Eswar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:30:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406781#M818132</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-14T03:30:56Z</dc:date>
    </item>
    <item>
      <title>Re: Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406782#M818133</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 the Syntax for Uploading the File from  Application Server .&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;  Retrieve Data file from Application server(Upload from Unix)&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;DATA: i_file like rlgrap-filename value '/usr/sap/tmp/file.txt'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    OPEN DATASET i_file FOR INPUT IN TEXT MODE.&lt;/P&gt;&lt;P&gt;    IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;      MESSAGE e999(za) WITH 'Error opening file' i_file.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;    DO.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    Reads each line of file individually&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      READ DATASET i_file INTO wa_datatab.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    Perform processing here&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    .....&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;    ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if it is usefull .....&lt;/P&gt;&lt;P&gt;Girish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:36:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406782#M818133</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-14T03:36:08Z</dc:date>
    </item>
    <item>
      <title>Re: Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406783#M818134</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Again Eswar, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you, it solved my problem. By the way, since the file that I am reading from&lt;/P&gt;&lt;P&gt;the app server is tab delimited, is there a way to split in respective fields of my itab?&lt;/P&gt;&lt;P&gt;Since I do not want to loop at my itab again to split  because it might cause performance&lt;/P&gt;&lt;P&gt;issue. Below is my current code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
OPEN DATASET lv_filename
             FOR INPUT IN TEXT MODE
        ENCODING DEFAULT
        IGNORING CONVERSION ERRORS.

    IF sy-subrc = 0.
      WHILE sy-subrc = 0.
        READ DATASET lv_filename INTO wa_ftp_recs.
        TRY.
          CATCH cx_sy_codepage_converter_init.
        ENDTRY.
        TRY.
          CATCH cx_sy_conversion_codepage.
        ENDTRY.
        APPEND wa_ftp_recs TO lt_ftp_recs.
        CLEAR wa_ftp_recs.
      ENDWHILE.
    ENDIF.

    CLOSE DATASET lv_filename.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you and take care!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:36:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406783#M818134</guid>
      <dc:creator>aris_hidalgo</dc:creator>
      <dc:date>2008-02-14T03:36:52Z</dc:date>
    </item>
    <item>
      <title>Re: Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406784#M818135</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;ABAP code for uploading a TAB delimited file into an internal table. See code below for structures. The code is base on uploading a simple txt file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  zuploadtab                    .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS: p_infile  LIKE rlgrap-filename&lt;/P&gt;&lt;P&gt;                        OBLIGATORY DEFAULT  '/usr/sap/'..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: ld_file LIKE rlgrap-filename.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Internal tabe to store upload data&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF t_record,&lt;/P&gt;&lt;P&gt;    name1 like pa0002-VORNA,&lt;/P&gt;&lt;P&gt;    name2 like pa0002-name2,&lt;/P&gt;&lt;P&gt;    age   type i,&lt;/P&gt;&lt;P&gt;    END OF t_record.&lt;/P&gt;&lt;P&gt;DATA: it_record TYPE STANDARD TABLE OF t_record INITIAL SIZE 0,&lt;/P&gt;&lt;P&gt;      wa_record TYPE t_record.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Text version of data table&lt;/P&gt;&lt;P&gt;TYPES: begin of t_uploadtxt,&lt;/P&gt;&lt;P&gt;  name1(10) type c,&lt;/P&gt;&lt;P&gt;  name2(15) type c,&lt;/P&gt;&lt;P&gt;  age(5)  type c,&lt;/P&gt;&lt;P&gt; end of t_uploadtxt.&lt;/P&gt;&lt;P&gt;DATA: wa_uploadtxt TYPE t_uploadtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*String value to data in initially.&lt;/P&gt;&lt;P&gt;DATA: wa_string(255) type c.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;constants: con_tab TYPE x VALUE '09'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*If you have Unicode check active in program attributes then you will&lt;/P&gt;&lt;P&gt;*need to declare constants as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*class cl_abap_char_utilities definition load.&lt;/P&gt;&lt;P&gt;*constants:&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   con_tab  type c value cl_abap_char_utilities=&amp;gt;HORIZONTAL_TAB.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&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;*START-OF-SELECTION&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;ld_file = p_infile.&lt;/P&gt;&lt;P&gt;OPEN DATASET ld_file FOR INPUT IN TEXT MODE ENCODING DEFAULT.&lt;/P&gt;&lt;P&gt;IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;  DO.&lt;/P&gt;&lt;P&gt;    CLEAR: wa_string, wa_uploadtxt.&lt;/P&gt;&lt;P&gt;    READ DATASET ld_file INTO wa_string.&lt;/P&gt;&lt;P&gt;    IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;      EXIT.&lt;/P&gt;&lt;P&gt;    ELSE.&lt;/P&gt;&lt;P&gt;      SPLIT wa_string AT con_tab INTO wa_uploadtxt-name1&lt;/P&gt;&lt;P&gt;                                      wa_uploadtxt-name2&lt;/P&gt;&lt;P&gt;                                      wa_uploadtxt-age.&lt;/P&gt;&lt;P&gt;      MOVE-CORRESPONDING wa_uploadtxt TO wa_upload.&lt;/P&gt;&lt;P&gt;      APPEND wa_upload TO it_record.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;  ENDDO.&lt;/P&gt;&lt;P&gt;  CLOSE DATASET ld_file.&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;*END-OF-SELECTION&lt;/P&gt;&lt;P&gt;END-OF-SELECTION.&lt;/P&gt;&lt;P&gt;*!! Text data is now contained within the internal table IT_RECORD&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Display report data for illustration purposes&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  loop at it_record into wa_record.&lt;/P&gt;&lt;P&gt;    write:/     sy-vline,&lt;/P&gt;&lt;P&gt;           (10) wa_record-name1, sy-vline,&lt;/P&gt;&lt;P&gt;           (10) wa_record-name2, sy-vline,&lt;/P&gt;&lt;P&gt;           (10) wa_record-age, sy-vline.&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;Reward  points if it is usefull ..&lt;/P&gt;&lt;P&gt;Girish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:45:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406784#M818135</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-14T03:45:39Z</dc:date>
    </item>
    <item>
      <title>Re: Error when passing data from app server...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406785#M818136</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use SPLIT command to get data into respective fields of structure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check below example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
DATA: str TYPE string.  " String

CONSTANTS: c_tab TYPE char01 VALUE
              cl_abap_char_utilities=&amp;gt;horizontal_tab.   " Tab Delimeter

OPEN DATASET &amp;lt;dsn&amp;gt; ....
IF sy-subrc eq 0.
   READ DATASET &amp;lt;dsn&amp;gt; INTO str.  " Read to String
   IF sy-subrc NE 0.
      EXIT.
   ELSE.
      SPLIT str AT c_tab INTO &amp;lt;wa&amp;gt;-fld1 &amp;lt;wa&amp;gt;-fld2 ... " Split at Delimeter into fields of work area
      APPEND &amp;lt;wa&amp;gt; TO &amp;lt;itab&amp;gt;. " Append Work Area to Structure
   ENDIF.
ELSE.
 ...." Error Message
ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Eswar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Feb 2008 03:51:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-passing-data-from-app-server/m-p/3406785#M818136</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-14T03:51:23Z</dc:date>
    </item>
  </channel>
</rss>

