<?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: file creation in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680717#M619558</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am planning download to application server&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 22 Aug 2007 08:28:05 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-08-22T08:28:05Z</dc:date>
    <item>
      <title>file creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680714#M619555</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;How to create sequential file and how to check it is created or not&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Aug 2007 08:22:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680714#M619555</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-22T08:22:01Z</dc:date>
    </item>
    <item>
      <title>Re: file creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680715#M619556</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;  to create seq file&lt;/P&gt;&lt;P&gt;use &lt;/P&gt;&lt;P&gt;open dataset &amp;lt;filename&amp;gt; for output in textmode encoding default.&lt;/P&gt;&lt;P&gt;here u can loop at itab and transfer the data to dataset&lt;/P&gt;&lt;P&gt;close dataset.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;u can see the file in tcode AL11&lt;/P&gt;&lt;P&gt;(application server files)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ex : &lt;/P&gt;&lt;P&gt;data : it_mara like table of mara with header line,&lt;/P&gt;&lt;P&gt;        v_rec(60),&lt;/P&gt;&lt;P&gt;        TAB(3) value '   ',&lt;/P&gt;&lt;P&gt;        coma type c value ','.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*****************************&lt;STRONG&gt;creating file on  application server&lt;/STRONG&gt;************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select matnr&lt;/P&gt;&lt;P&gt;       mtart&lt;/P&gt;&lt;P&gt;       ernam&lt;/P&gt;&lt;P&gt;       matkl&lt;/P&gt;&lt;P&gt;       meins from mara&lt;/P&gt;&lt;P&gt;     into corresponding fields of&lt;/P&gt;&lt;P&gt;     table it_mara.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;open dataset 'matdet.txt' in text mode encoding default for output.&lt;/P&gt;&lt;P&gt;  if sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;    exit.&lt;/P&gt;&lt;P&gt;  endif.&lt;/P&gt;&lt;P&gt;  loop at it_mara.&lt;/P&gt;&lt;P&gt;    concatenate it_mara-matnr it_mara-mtart it_mara-ernam into v_rec separated by coma.&lt;/P&gt;&lt;P&gt;    transfer v_rec to 'matdet.txt'.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   transfer it_mara to 'matdet.txt'.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  endloop.&lt;/P&gt;&lt;P&gt;  if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;    message i000(bctrain) with 'File created on application server'.&lt;/P&gt;&lt;P&gt;  endif.&lt;/P&gt;&lt;P&gt;close dataset 'matdet.txt'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Premalatha G&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Aug 2007 08:25:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680715#M619556</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-22T08:25:42Z</dc:date>
    </item>
    <item>
      <title>Re: file creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680716#M619557</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;can you please elaborate as what do you mean by sequential file. are you planning to downlaod it on Application server or Presentation Server. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kanchan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Aug 2007 08:27:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680716#M619557</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-22T08:27:11Z</dc:date>
    </item>
    <item>
      <title>Re: file creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680717#M619558</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am planning download to application server&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Aug 2007 08:28:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680717#M619558</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-22T08:28:05Z</dc:date>
    </item>
    <item>
      <title>Re: file creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680718#M619559</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rakesh, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check out the below code and you shall get the solution that you are looking for,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Check for the existence of the file.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;       CALL FUNCTION 'TMP_GUI_GET_FILE_EXIST'&lt;/P&gt;&lt;P&gt;           EXPORTING&lt;/P&gt;&lt;P&gt;                FNAME          = P_IPERR      "file name along with the path&lt;/P&gt;&lt;P&gt;           IMPORTING&lt;/P&gt;&lt;P&gt;                ISDIR          = L_ISDIR    "-------L_ISDIR is a variable of Char (1)&lt;/P&gt;&lt;P&gt;           EXCEPTIONS&lt;/P&gt;&lt;P&gt;                FILEINFO_ERROR = 1&lt;/P&gt;&lt;P&gt;                OTHERS         = 2.&lt;/P&gt;&lt;P&gt;      IF SY-SUBRC &amp;lt;&amp;gt; 0.&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;      IF L_ISDIR EQ C_TRUE.&lt;/P&gt;&lt;P&gt;        MESSAGE I000 WITH TEXT-&amp;lt;xxx&amp;gt;.&lt;/P&gt;&lt;P&gt;        STOP.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;to create that file&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    OPEN DATASET P_IPERR1 FOR OUTPUT IN TEXT MODE. "----P_IPERR1 is the filename in the application layer.&lt;/P&gt;&lt;P&gt;      CHECK SY-SUBRC EQ 0.&lt;/P&gt;&lt;P&gt;      CLEAR WA_ERR_REC.&lt;/P&gt;&lt;P&gt;      LOOP AT I_ERR_REC INTO WA_ERR_REC. "--I_ERR_REC is an internal table having the data to be written to flat file.&lt;/P&gt;&lt;P&gt;        IF WA_ERR_REC-DEL_FLAG = C_TRUE.&lt;/P&gt;&lt;P&gt;          TRANSFER WA_ERR_REC TO P_IPERR1.&lt;/P&gt;&lt;P&gt;        ENDIF.&lt;/P&gt;&lt;P&gt;        CLEAR WA_ERR_REC.&lt;/P&gt;&lt;P&gt;      ENDLOOP.&lt;/P&gt;&lt;P&gt;      CLOSE DATASET P_IPERR1.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;&lt;/P&gt;&lt;P&gt;Rewards points if this helps,&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Kiran&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Kiran Kumar Somaroutu&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Kiran Kumar Somaroutu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Aug 2007 08:31:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/file-creation/m-p/2680718#M619559</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-22T08:31:39Z</dc:date>
    </item>
  </channel>
</rss>

