Entire Table not visible/ transferred to a file on application server

HI Experts,
My req is to pass an entire internal table to a file on the application server.
How ever some of the fields in the table are not shown / transferred when i check that file.
The fields are not visible when i try to scroll side wise.
When I download the internal table to an excel all the fileds are present . There is no problem with the internal table that is being transferred.
Below is the code snippet.
CLEAR w_filepath.
    MOVE p_file TO w_file_ext.
    CALL FUNCTION 'FILE_GET_NAME_USING_PATH'
      EXPORTING
        logical_path               = c_zstore
        file_name                  = w_file_ext
      IMPORTING
        file_name_with_path        = w_filepath
      EXCEPTIONS
        path_not_found             = 1
        missing_parameter          = 2
        operating_system_not_found = 3
        file_system_not_found      = 4
        OTHERS                     = 5.
    IF sy-subrc NE 0.
      MESSAGE e068(zz_material).
*   File could not be downloaded to the application server
    ELSE.
      OPEN DATASET w_filepath FOR OUTPUT IN TEXT MODE ENCODING DEFAULT.
      IF sy-subrc NE 0.
        MESSAGE e069(zz_material).
*   Unable to Open File
      ENDIF.
      CLEAR:rec_final.
      LOOP AT t_final INTO rec_final.
        TRANSFER rec_final TO w_filepath.
        CLEAR rec_final.
      ENDLOOP.
      CLOSE DATASET w_filepath.
Are there any limitations on the no char that can be displayed in one line on the application server.
Is there any seeting to change that...?

Hello Abhishek,
You are not getting the point. AL11 (prog. RSWATCH0) is a simple report used to display the file contents.
There is a limitation to the maximum length of the file line AL11 can DISPLAY (i.e., 512 characters after applying the notes).
Please understand what you are seeing in AL11 is the 1st 512 characters of the file width & not the entire file width.
Hope you get the point.
BR,
Suhas

Similar Messages

  • Not recognizing # while reading the file from application server

    Hi
    I am reading a file from application server. While reading into internal table with read statement the last field in each record is filling with hash symbol in the last digit. If I write any if condition with HASH symbol its not going inside the if condition, means its not recognizing as hash may be its internally treating as some other. I need to remove the hash from that field. How I can do that.
    Thanks,
    kishore

    I faced exact situation. Yes, internally its treated as some other special character. What i did was, becuase hash symbol was always coming at the end...i created a dummy field in my internal table so that it will not interfere with my actual data. When i see the data in my internal table, the hash always falls in the last field (dummy) which i will ignore. I could not get solution to remove this hash so i adopted this approach and it worked!!
    Hope it helps,
    SKJ

  • Field not visible when uploading the file in application ser

    Hi,
    I have added a new field at the end of a structure and When i upload the data in the application server it is not visible there. The new field length is 30chars(say field 'A')  and the one just before this one is 250 chars(say field 'B'). When i reduce the length of field 'B' to 30 chars or 40 chars the value which i populated in field 'A' is visble in the output file.
    Since the complete file was not visible in AL11 transaction, i used the CG3Y tcode as well to download the data to presentation server so that i can view the complete file. Even after downlaoding in presentation server the new field value is not visible.
    Can anyone please suggest why is the value in field 'A' not visible when the length of field 'B' is 250 chars? Also, how can i display the value of the new field in the application server.I cannot change the layout of the structure as per the requirement. Any help will be very useful.
    Thanks in advance,
    Sneha.

    Hi Sneha.. Happy new year
    <you subject is missing ver from the server, thats why your server doesnt like you :P>
    -ok, lets go step by step. how did you upload the file?
    -after uploading the file check the file in OS level(goto SM69, execute CAT, in additional parameter (not in parameter) give the full path (case sensitive), execute. ). here you can see the actual content of the file... check you data is present or not
    -which structure are you using to download and upload? a temp work area.. then please provide the WA details, so that i can try on my system.
    lets see what happens next
    one more thing: regarding AL11, it can read upto length 510 characters. check program RSWATCH0 form SHOW_FILE. here the read dataset into butffer is 510 characters.

  • Error when loading a flat file from Application server.

    Hi,
    I am trying to load a flatfile from the application server, and I am getting the message
    Error while accessing the application server file
    Message no. RSDS_ACCESS002
    I checked for notes and found only one:
    Note 1033978 - Correction: Loading Unicode files from application server
    but we have 19 SP level, and the note says it needs 13 SP level, so I think it would not be of any help.
    does anybodie know what to do??
    thanks for the help.
    Mauricio

    Error in accessing while application server file..
    when i am trying load the data to psa
    when i am taking the file name: text-type file from app server
    plz reslove me for this problem??
    another question
    when i am saving the file with using * in the  filename in .CSV file its not saving,
    whats the reason????
    ASHOK

  • Transfering data from bsis table to file on application server

    Hi Gurus,
    In my program iam selecting data from bsis table and transferring to file on the application server.
    Code:
    Tables: BSIS.
    data: file type rlgrap-filename.
    Select * from BSIS into BSIS.
    Open dataset output in text mode encoding default.
    Transfer bsis to file.
    closesdataset.
    1, Issue when transferring iam getting dump due to type conflict.
    2, Here I cant create a structure like bsis and define type c  
        varialbles as its an upgrade project.
    3, I tried field-symbols using type casting but data in the
        application server is showing junk data with ##### in currncy
        fields.
    4, In earlier program there is no internal table defined for bsis,
        Directly passing to work area and transferring to file on
        application server.
    Please let me know any feasble solution to approach.
    If need i can post the complete code.
    Regards
    Bhaskar

    Hi Robert,
    Here is my code....in ECC. While executing program is going to dump saying character type error.
    tables: bsis.
    data: begin of i_tab occurs 100.
            include structure bsis.
            end of i_tab.
    parameters: outfile(1000) lower case.
    open dataset outfile for output in text mode encoding default
    ignoring conversion errors..
    select * from bsis into table i_tab
    where bukrs = bukrs.
       loop at i_tab.
          transfer i_tab to outfile.
       endloop.
      close dataset.
    Please let me know if any soluton.
    regards
    Bhaskar

  • XML data into Oracle Tables. XML file on Application Server.Oracle Apps R12

    Hi All,
    My Database version : 11.2.0.2.0
    I have an XML file which needs to be loaded into the Database Tables. How ever i do not want to use the XMLTYPE as given below
    insert into test1 (
    SELECT PrcDate, PmtType, PmtStatus, PmtTypeCount, PmtTypeAmt
    FROM XMLTABLE(
    '/WFPaymentAck/RejectedDom1ACH'
    PASSING XMLTYPE( BFILENAME('ECX_UTL_LOG_DIR_OBJ','wf_test_xml.XML'), NLS_CHARSET_ID('UTF8') )
    COLUMNS
    PrcDate VARCHAR2(2000) PATH '@PrcDate' ,
    PmtType VARCHAR2(2000) PATH '@PmtType' ,
    PmtStatus VARCHAR2(100) PATH '@PmtStatus' ,
    PmtTypeCount VARCHAR2(100) PATH 'PmtTypeCount' ,
    PmtTypeAmt VARCHAR2(100) PATH 'PmtTypeAmt'
    Because this way the XML file needs to reside on the DB server.
    I am looking into other option of loading the XML file into a CLOB column of a table and reading it from that column.
    I did a couple of tests and feel that this way also the XML file has to reside on the Database Server itself. I am not sure if this is correct or if there is any problem with our TEST instance.
    ++Can anyone let me know if i need to have the XML file on the DB server instead of the Application server to load into a CLOB column of table ??++
    ++Or++
    ++Is there any other workaround for me to load XML into Oracle Tables, while having the XML file on Application Server.++
    Your immediate help is appreciated. I need to get past this ASAP.
    Thanks in Advance.
    VJ

    1) Are you asking me to create a folder on Database directory which points to a folder on the Apps server ?I suggest creating an Oracle directory object (a database object) pointing to a real location (folder) on Application server.
    we DONOT want a hand shake between the DB Server and the APPS server.I don't see where the problem is.
    I'm not familiar with Apps R12 but there's no doubt the two servers are already communicating, at least App server should be able to access the DB for the whole thing to run.
    As I said :
    One way or another, the data has to make its way to the database, there's no workaround to that.How do you imagine the data will end up in a database table if it doesn't come to the DB server?
    There's no magical method out there, both servers have to communicate at some point.
    About client-server approaches (client being here the App server), you can read about accessing the XML DB repository in the XML DB Developer's Guide : http://download.oracle.com/docs/cd/E11882_01/appdev.112/e23094/toc.htm
    Other option : SQL*Loader can load a CLOB, or an XMLType column too
    Edited by: odie_63 on 19 déc. 2011 20:22

  • Error while reading excel file from application server into internal table.

    Hi experts,
    My requirement is to read an excel file from application server into internal table.
    Hence I have created an excel file fm_test_excel.xls in desktop and uploaded to app server using CG3Z tcode (as BIN file type).
    Now in my program I have used :
    OPEN DATASET v_filename FOR INPUT IN text mode encoding default.
    DO.
    READ DATASET v_filename INTO wa_tab.
    The statement OPEN DATASET works fine but I get a dump (conversion code page error) at READ DATASET statement.
    Error details:
    A character set conversion is not possible.
    At the conversion of a text from codepage '4110' to codepage '4103':
    - a character was found that cannot be displayed in one of the two
    codepages;
    - or it was detected that this conversion is not supported
    The running ABAP program 'Y_READ_FILE' had to be terminated as the conversion
    would have produced incorrect data.
    The number of characters that could not be displayed (and therefore not
    be converted), is 445. If this number is 0, the second error case, as
    mentioned above, has occurred.
    An exception occurred that is explained in detail below.
    The exception, which is assigned to class 'CX_SY_CONVERSION_CODEPAGE', was not
    caught and
    therefore caused a runtime error.
    The reason for the exception is:
    Characters are always displayed in only a certain codepage. Many
    codepages only define a limited set of characters. If a text from a
    codepage should be converted into another codepage, and if this text
    contains characters that are not defined in one of the two codepages, a
    conversion error occurs.
    Moreover, a conversion error can occur if one of the needed codepages
    '4110' or '4103' is not known to the system.
    If the conversion error occurred at read or write of  screen, the file
    name was '/usr/sap/read_files/fm_test_excel.xls'. (further information about
    the file: "X 549 16896rw-rw----201105170908082011051707480320110517074803")
    Also let me know whether this is the proper way of reading excel file from app server, if not please suggest an alternative .
    Regards,
    Karthik

    Hi,
    Try to use OPEN DATASET v_filename FOR INPUT IN BINARY mode encoding default. instead of OPEN DATASET v_filename FOR INPUT IN text mode encoding default.
    As I think you are uploading the file in BIN format to Application server and trying to open text file.
    Regards,
    Umang Mehta

  • How best store files on application server: Tables vs File system

    Hi Experts,
    We want to let users to upload files to application server. The number of files can potencially grow over time (1000 files every month) though I whould like to limit size of each file not more than 1-2 MB.
    Also files should be classified (having custom attributes) so later on we need to search, select files according to attributes.
    So what are the best options in long run (for performance, reliability etc)?
    We have NW system 7.0 with MaxDB
    I can think of the following options:
    1. Store files in TRANSPARENT table in RAWSTRING. Easiest variant (to select files etc) Here I have concerns how this table and database behave after some period of time and what will happen if size will grow to let say 50 GB. Will it work? What are normal size limits for transparent tables?
    2. Store files in CLUSTER table in RAWSTRING. Less convenient to work with (joins are not allowed etc). Will cluster table help to handle big size of table? What are practical size limits for cluster tables?
    3. Store files on file system (on application server) and write info (attributes etc) into ztable. Select from ztable and read content file from file system (dataset commands?). So files will be written to one directory just one after another.
    What are the best option to follow? I would personally prefer option 1 as easiest but have servious concerns regarding size of one transparent table.
    What do you recommend?
    Regards,
    Dmitry.
    Edited by: Dmitry Kalmykov on Jul 28, 2009 8:58 AM

    Hi,
    I too feel that option 1 would be best choice.
    For your ref: Check the Transp.table REPOSRC and the field name DATA
    Also Check the technical settings (Size category).

  • How to upload a file in application server to an internal table

    Hi,
          I am asked to upload a file from application server to internal table. Can you please suggest me the ways to do it or the function module which helps to browse the application server file names.
      I have done a program. But its giving problem in searching the files from application server. I am pasting my code for ur review. Please tell me which part i have to correct or suggest me some other ways to do it.
    *& Report  ZUPLOAD1
    REPORT  ZUPLOAD1.
    type-pools: truxs.
    parameters: p_upl_ps radiobutton group g1 default 'X', "upload from pres. server
                 p_path type rlgrap-filename, 
                 p_upl_as radiobutton group g1,   "upload from appln server
                 <b>p_dir LIKE filepath-pathintern DEFAULT 'Y_ABAP', 
                 p_file LIKE filepath-pathintern lower case,</b>      
                 p_test as checkbox.
    constants: c_x value 'X',
               c_tab type c value cl_abap_char_utilities=>horizontal_tab.
    types: ty_data(1000) type c.    "structure to hold legacy data
    data: i_data type standard table of ty_data. "internal table of ty_data
    types: begin of stritab,
          land1 type v_t604-land1,  "structure of legacy file.
          stawn type v_t604-stawn,
          bemeh type v_t604-bemeh,
          impma type v_t604-impma,
          minol type v_t604-minol,
          end of stritab.
    data: gi_itab type standard table of stritab, "internal table of legacy file
          gw_itab type stritab.  "work area
    data: i_raw type truxs_t_text_data,
          v_fullpath type string.
    at selection-screen on value-request for p_path.
    if p_upl_ps = c_x. "if presentation server is selected
    perform get_file.
    else.            "if application server is selected
    perform set_file_path.      
    perform upload_from_server.
    perform split_data.
    endif.
    form get_file.
    CALL FUNCTION 'F4_FILENAME'
    EXPORTING
      PROGRAM_NAME        = SYST-CPROG
      DYNPRO_NUMBER       = SYST-DYNNR
      FIELD_NAME          = ' '
    IMPORTING
       FILE_NAME           = p_path.     "getting the file name of pres server
    CALL FUNCTION 'TEXT_CONVERT_XLS_TO_SAP'
      EXPORTING
      I_FIELD_SEPERATOR          =
        I_LINE_HEADER              = 'X'              "converting excel to sap and filling in
        I_TAB_RAW_DATA             = i_raw      "internal table
        I_FILENAME                 = p_path
      TABLES
        I_TAB_CONVERTED_DATA       = gi_itab
    EXCEPTIONS
       CONVERSION_FAILED          = 1
       OTHERS                     = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    endform.
    form set_file_path.                 "Getting the file path of application server
    data: lv_file type p_file.
          lv_file = p_file.
          CALL FUNCTION 'FILE_GET_NAME_USING_PATH'
            EXPORTING
            CLIENT                           = SY-MANDT
              LOGICAL_PATH                     = p_dir
            OPERATING_SYSTEM                 = SY-OPSYS
            PARAMETER_1                      = ' '
            PARAMETER_2                      = ' '
            PARAMETER_3                      = ' '
            USE_BUFFER                       = ' '
              FILE_NAME                        = lv_file
            USE_PRESENTATION_SERVER          = ' '
            ELEMINATE_BLANKS                 = 'X'
           IMPORTING
             FILE_NAME_WITH_PATH              = v_fullpath
           EXCEPTIONS
             PATH_NOT_FOUND                   = 1
             MISSING_PARAMETER                = 2
             OPERATING_SYSTEM_NOT_FOUND       = 3
             FILE_SYSTEM_NOT_FOUND            = 4
             OTHERS                           = 5
          IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
          ENDIF.
    endform.
    form upload_from_server.
    data: lv_msg type string,
          lw_data type ty_data.
    open dataset v_fullpath for input message lv_msg in text mode encoding default.
    if sy-subrc <> 0.
    message lv_msg type 'i'.
    stop.
    endif.
    do.
    read dataset v_fullpath into lw_data.
    if sy-subrc <> 0.
    write:/5 'Error in processign data set'.
    exit.
    endif.
    append lw_data to i_data.
    enddo.
    close dataset v_fullpath.
    if sy-subrc <> 0.
    write: /5 'Error closing dataset'.
    endif.
    endform.
    form split_data.
    data: lw_data type ty_data.
    data: lw_itab type stritab.
    data: begin of ty_itab,
          land1 type v_t604-land1,
          stawn type v_t604-stawn,
          bemeh type v_t604-bemeh,
          impma type v_t604-impma,
          minol type v_t604-minol,
          end of ty_itab.
    loop at i_data into lw_data.
    split lw_data at c_tab into
          ty_itab-land1
          ty_itab-stawn
          ty_itab-bemeh
          ty_itab-impma
          ty_itab-minol.
    lw_itab-land1 = ty_itab-land1.
    lw_itab-stawn = ty_itab-stawn.
    lw_itab-bemeh = ty_itab-bemeh.
    lw_itab-impma = ty_itab-impma.
    lw_itab-minol = ty_itab-minol.
    append lw_itab to gi_itab.
    endloop.
    endform.
    start-of-selection.
    loop at gi_itab into gw_itab.
    write: /5 'COUNTRY', 'IMPORT CODE', 'SUP UNIT', 'FIRST UOM', 'SECOND UOM',
           /5 gw_itab-land1, gw_itab-stawn,gw_itab-bemeh,gw_itab-impma,gw_itab-minol.
    endloop.
    end-of-selection.
    I hope problem must be in p_dir and p_file which are in bold.. Kindly help me out. Thanks in advance.

    see the following ex:
    *&      Form  SUB_GET_FILEPATH
          text
    -->  p1        text
    <--  p2        text
    FORM SUB_GET_FILEPATH .
        GFILE = 'D:\SAP_INT\INBOUND\INBOX'.  "Path
    ENDFORM.                    " SUB_GET_FILEPATH
    *&      Form  SUB_GET_FILE
          text
    -->  p1        text
    <--  p2        text
    FORM SUB_GET_FILE .
      DATA: P_FDIR(200) TYPE C.
      DATA: IT_FILEDIR1 TYPE STANDARD TABLE OF TY_FILEDIR WITH HEADER LINE.
      P_FDIR = GFILE.
      CALL FUNCTION 'RZL_READ_DIR_LOCAL'
        EXPORTING
          NAME     = P_FDIR
        TABLES
          FILE_TBL = IT_FILEDIR.
      REFRESH : IT_FILEDIR1.
      LOOP AT IT_FILEDIR.
        IF IT_FILEDIR-NAME(4) = 'ZINC' OR IT_FILEDIR-NAME(4) = 'zinc'.
          MOVE IT_FILEDIR-NAME TO IT_FILEDIR1-NAME.
          APPEND IT_FILEDIR1.
        ENDIF.
      ENDLOOP.
      IF IT_FILEDIR1[] IS INITIAL.
        STOP.
      ENDIF.
      LOOP AT IT_FILEDIR1.
        REFRESH: I_TAB.
        CLEAR: I_TAB.
        NAME = IT_FILEDIR1-NAME.
        CONCATENATE: GFILE '\' NAME INTO G_FILE.
        OPEN DATASET G_FILE FOR INPUT IN TEXT MODE
                                         ENCODING DEFAULT
                                         IGNORING CONVERSION ERRORS.
        IF SY-SUBRC EQ 0.
          CONCATENATE 'FILENAME  : ' G_FILE INTO I_MSG1.
          APPEND I_MSG1.
          DO.
            READ DATASET G_FILE INTO RECORD.
            IF SY-SUBRC = 0.
              SPLIT RECORD AT ',' INTO I_TAB-BUKRS  I_TAB-EBELN
                  I_TAB-BLDAT  I_TAB-XBLNR I_TAB-LIFNR I_TAB-AMOUNT
                  I_TAB-CURR  I_TAB-BUSAREA
                  I_TAB-BKTXT I_TAB-DMBTR I_TAB-MENGE I_TAB-SRNO.
              MOVE-CORRESPONDING I_TAB TO I_TAB1.
            ELSE.
              EXIT.
            ENDIF.
            APPEND I_TAB1.
            CLEAR: I_TAB, I_TAB1.
          ENDDO.
        ENDIF.
        CLOSE DATASET G_FILE.

  • InfoSpoke fails with message "Could not open file on application server"

    BW Experts,
    I created an InfoSpoke that is configured to extract to a flat file. The name of the file is specified using a logical filename. During extraction, the infospoke reports the error message "Could not open file on application server" adnd  marks the extraction process as red(failed). I have tried to run the InfoSpoke in background mode and in dialog mode and the same error appears. After i run in dialog mode, i checked SU53 for authorization errors and did not find any. I also tried changing the Logical filename setup in transaction FILE to a more "friendly" directory in which i'm sure i have authorizations (e.g. my UNIX home directory) and im still getting errors.
    Can you please share your thoughts on this? Any help will greatly appreciated. I also promise to award points.

    Hi Nagesh,
    Thanks for helping out.
    If i configure the InfoSpoke to download to a file using "File Name" option and also check the "Application server" checkbox, the extract works correctly (extraction to the defualt SAP path and filename=infospoke name). If i configure the InfoSpoke to download to the local workstation, the InfoSpoke also works correctly. It's only when i configure it to download to the application server and use the "Logical filename" option, that i encounter a failed extract.
    Here are the messages is the Open Hub Monitor:
    (red icon) Request No.147515
    0 Data Records
    Runtime 1 sec.
    (red icon)Run No. 1
    0 Data Records
    Runtime 1 sec.
    Messages for Run
    Extraction is running RSBO 305
    Could not open file on application server RSBO 214
    Request 147515 was terminated before extraction RSBO 326
    Request 1475151: Error occured RSBO 322
    If i clink on the error message, no messages nor clues are displayed. Note, this is a new InfoSpoke that is currently in the dev system.
    Please help.

  • Reading XML file from application server and  put into internal table-4.6C

    Dear All,
    Is there any way of reading XML file from application server to SAP? I am using 4.6C. Function module SCMS_STRING_TO_XSTRING function module is not available. Please suggest.
    Thanks and regards,
    Atanu

    Hi Atanu!
    Simply use the XSLT transformation 'ID'.
    FIELD-SYMBOLS <ls_result> TYPE ANY.
    CREATE DATA lref_data TYPE (your_structure).
    ASSIGN lref_data->* TO <ls_result>.
    CALL TRANSFORMATION id
                        SOURCE XML xmlstr
                        RESULT result = <ls_result>.
    "xmlstr" contains your XML file. Just read it into it via standard I/O operations. "<ls_result>" will contain your DDIC formatted content.
    Best regards
    Torsten

  • Upload XML file from Application Server to Internal Table

    Hi Experts,
       i have xml file in application server and i want to convert to internal table .
       i have tried this link http://wiki.sdn.sap.com/wiki/display/ABAP/UploadXMLfiletointernal+table.
       Here the file is loaded from local(presentation Server) ..
       i want to know how to select file from application layer ..and schedule in background..
       i also tried  FM '/SAPDMC/LSM_F4_SERVER_FILE' but this need front end selection of file from application server..
       i need to select a xml file from application server and convert into internal table in background.. help me on this..

    Have a look on
    Re: How to convert XML data to different ABAP internal table
    Thanks
    Ravin

  • Not able to get file from application server with read dataset

    Hi,
    Firstly i download a file from application server from read data set and then i sent this file as attachment. But problem is that i am able to send .jpg .bmp file but i am not able to send .pdf or .doc file so what can i do for that. ?
    My code is like below...
      DATA : PATH TYPE STRING.
      DATA: E_FILE LIKE RLGRAP-FILENAME.
      CONCATENATE '/tmp/'  NAME_WITH_EXT INTO E_FILE SEPARATED BY SPACE.
      CONDENSE E_FILE NO-GAPS.
      IF EXTENSION = 'TXT'.
        OPEN DATASET E_FILE FOR INPUT IN TEXT MODE ENCODING DEFAULT WITH WINDOWS LINEFEED . " MESSAGE MSG.
        IF SY-SUBRC <> 0.
       WRITE: SY-SUBRC, MSG, ' LIKE ', C_FNAME.
        ELSE.
          WHILE SY-SUBRC = 0.
            READ DATASET E_FILE INTO WA_C.
            IF SY-SUBRC <> 0.
              EXIT.
            ENDIF.
            APPEND WA_C TO IT_C.
          ENDWHILE.
          CLOSE DATASET E_FILE.
        ENDIF.
      ELSE.
        OPEN DATASET E_FILE FOR INPUT IN BINARY MODE. " ENCODING DEFAULT. "    INPUT IN  BINARY MODE . " TEXT MODE ENCODING   NON-UNICODE.
        IF SY-SUBRC = 0.
          DO .
            READ DATASET E_FILE INTO GS_PDF_TAB.
            IF SY-SUBRC = 0.
              APPEND GS_PDF_TAB TO GT_PDF_TAB.
            ELSE.
              EXIT.
            ENDIF.
          ENDDO.
          CLOSE DATASET E_FILE.
        ENDIF.
      ENDIF.
    Regards,
    Gurprit Bhatia

    delete this line DEFAULT WITH WINDOWS LINEFEED  and check this..

  • Could not open the file in application server

    Hi All,
    I have a Zreport which will write files on application server. When I tried to download it is showing me "Could not open the file". And when checked again with /nal11 the files does not exist. When I ran the Zreport again the file exist in application server but unable to download. And when checked again the file doesnot  exist. Why it is getting archived? Please help me.
    Thanks,
    Venkata

    Hi Sagar,
    Below is my file path : /dv2/tmp/instl/salesdata.txt
    When I checked in the below path the file exists.
    /dv2/tmp/archive/salesdata.txt
    Solved the issue.
    Thanks,
    Venkata

  • Write internal table to a file on application server using OPEN DATASET

    I have logical file path and XLS file name. I want to write internal table to a XLS or CSV file on application sever. Please give example.

    Hi
    see this program
    EXCEL SHET to INTERNAL table and then to APPLICATION server
    *& Report  ZSD_EXCEL_INT_APP
    REPORT  ZSD_EXCEL_INT_APP.
    parameter: file_nm type localfile.
    types : begin of it_tab1,
            f1(20),
            f2(40),
            f3(20),
           end of it_tab1.
    data : it_tab type table of ALSMEX_TABLINE with header line,
           file type rlgrap-filename.
    data : it_tab2 type it_tab1 occurs 1,
           wa_tab2 type it_tab1,
           w_message(100)  TYPE c.
    at selection-screen on value-request for file_nm.
    CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
    EXPORTING
      PROGRAM_NAME        = SYST-REPID
      DYNPRO_NUMBER       = SYST-DYNNR
      FIELD_NAME          = ' '
       STATIC              = 'X'
      MASK                = ' '
      CHANGING
       file_name           = file_nm
    EXCEPTIONS
       MASK_TOO_LONG       = 1
       OTHERS              = 2
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    start-of-selection.
    refresh it_tab2[].clear wa_tab2.
    file = file_nm.
    CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
      EXPORTING
        filename                      = file
        i_begin_col                   = '1'
        i_begin_row                   =  '1'
        i_end_col                     = '10'
        i_end_row                     = '35'
      tables
        intern                        = it_tab
    EXCEPTIONS
       INCONSISTENT_PARAMETERS       = 1
       UPLOAD_OLE                    = 2
       OTHERS                        = 3
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    loop at it_tab.
      case it_tab-col.
       when '002'.
        wa_tab2-f1 = it_tab-value.
       when '004'.
        wa_tab2-f2 = it_tab-value.
      when '008'.
        wa_tab2-f3 = it_tab-value.
    endcase.
    at end of row.
      append wa_tab2 to it_tab2.
    clear wa_tab2.
      endat.
    endloop.
    data : p_file TYPE  rlgrap-filename value 'TEST3.txt'.
    OPEN DATASET p_file FOR OUTPUT IN TEXT MODE ENCODING DEFAULT.
    *--- Display error messages if any.
      IF sy-subrc NE 0.
        MESSAGE e001(zsd_mes).
        EXIT.
      ELSE.
    *---Data is downloaded to the application server file path
        LOOP AT it_tab2 INTO wa_tab2.
          TRANSFER wa_tab2 TO p_file.
        ENDLOOP.
      ENDIF.
    *--Close the Application server file (Mandatory).
      CLOSE DATASET p_file.
    loop at it_tab2 into wa_tab2.
      write : / wa_tab2-f1,wa_tab2-f2,wa_tab2-f3.
    endloop.

Maybe you are looking for

  • User-Exit to limit the unplanned delivery costs in a PO

    Hi All, My Requirement is that I need to Limit the Unplanned Delivery Costs in a Purchase Order.I find there exists no ways to arrive at this through Customizations.Could anybody please guide me If this can be Fulfilled through a User Exit.If yes,cou

  • AP not joining

    Hi all, I could need a little help troubleshooting some AP issue. For some reason some AP will not join the WLC. (WISMII) I have several hundrede AP online, but still a few offline This fails: FRH-R06-L226-UX-G#sh cdp nei gi2/0/41 detail Device ID: A

  • My printer/scanner is not showing up under TWAIN acquire under pse's import on my imac. can anyone help?

    i cannot scan documents to photoshop. the all-in-one printer was installed after i installed pse 11. do i need to reinstall pse?

  • COI: manual postings that can be interpreted by COI on divestiture

    Hello Experts I hope you can help. I am using COI functionality at a customer. I need to post a manual journal on posting level 30 against a minority interest item as an example. The journal should be recognised by the activity 'Divestiture' at a lat

  • Airport 3.0.4 for Mac os X

    I have been looking for a airport update for my computer. currently I have Airport 2.1.1 I think. I found this link: http://docs.info.apple.com/article.html?artnum=120200 but that is mac os x 10.1.5 Then I found this link: http://docs.info.apple.com/