Reading the Excel from Content Server...

Hello Experts
I have a requirement to read the contents of the excel from DMS content server to Internal Table.
I tried using the function module "SCMS_DOC_READ", but it is reading only the part of the contents and remaining contents are missing in the Internal Table.
Is there any other way to read the content of excel file stored in content server.
Many Thanks in advance!!!
Regards,
Benu

Hi Christoph,
Many thanks for your reply...
Now I am using the same report for downloading the document from content server but my requirement is to read the contents directly from content server without downloading it to presentation server..
The function module mentioned in the above post is not reading the complete contents of the excel sheet.
Regards,
Benu

Similar Messages

  • Regarding Reading the file from Application Server

    Hi,
    I am trying to read data from Application Server but due to special characters it is getting dumped out.
    US24,Q,Acero (Carbon),AA,0010,0001,01,Ver Mir para dimension#
    US24,Q,Acero (Carbon),AA,0010,0002,01,Area rectificada sin da#os ra
    US24,Q,Acero (Carbon),AA,0010,0003,01,Ver Mir para dimension#
    US24,Q,Acero (Carbon),CD,0010,0001,01,ITPE Soken para verificacion
    US24,Q,Acero (Carbon),CD,0010,0010,01,No se permite desprendimiento
    US24,Q,Acero (Carbon),CD,0010,0002,01,"Vernier, cinta metrica"#
    In the last line it is going into dump due to special character ".
    Please suggest.
    Thanks
    Priyanka.

    Hi,
    You can check the mode in which you are reading the file
    from application server that is
    Open Dataset in Binary or Text Mode.
    Hope it helps
    Regards
    Mansi

  • Error in reading the mails from POP3 server

    Hi,
    I am reading mails from the POP3 server using UTL_TCP package. I am able to retrieve .txt & .doc attachments successfully.
    I am facing an error when I try to retrieve an attachment with a very long name (irrespective of the file type). Also, I am unable to retrieve .docx, .xls, .xlsx file types. I noticed similarity in the reasons for the error I am getting. I realized that if I try to retrieve an attachment with a very long file name or any of the above mentioned file formats (.docx, .xls, etc.), the "name" attribute of the attachment goes to the next line and hence I am going wrong somewhere in parsing that line.(The complete line comprises of : Content-Type: application/vnd.openxmlformatsofficedocument.wordprocessingml.document; name="test_attachment.docx")
    I realized this pattern by doing executing Telnet commands to retrieve emails from POP3 server.
    I am trying to parse the line I am talking about in the following manner:
    IF line LIKE 'Content-Type: %;'
                   THEN
                        IF line LIKE 'Content-Type: %; name=%'
                        THEN
                             PIPE ROW (line);
                        ELSE
    -- This should only print the "Content-Type". But I get an error (pasted below) at this point
                             PIPE ROW (line);
    -- To read the "name" attribute which comes on the next line. But this line never gets executed since I get an error in the previous statement
                             BYTES := UTL_TCP.available (socket);
                             BYTES := UTL_TCP.read_line (socket, line);
                             PIPE ROW (line);
                        END IF;
    The error I get is :
    ERROR:
    ORA-29261: bad argument
    ORA-06512: at "SYS.UTL_ENCODE", line 29
    ORA-06512: at "SYS.UTL_ENCODE", line 251
    ORA-06512: at "SCOTT.POP3", line 117
    Message was edited by:
    Monk
    Message was edited by:
    Monk

    Hi,
    Try to manually download the file from application server using standard transactions, and than check how many records are you able to download from app. server.
    I guess there might be something wrong with the format of 583rd record, which makes sap assume that the file has come to an end.
    Hope this will help you.
    Regards,
    Vinit...

  • Problem while reading the file from FTP server

    Hi Friends,
    I have a problem while fetching files from FTP server.
    I used FTP_Connect, FTP_COMMAND function modules. I can able to put the files into FTP server.
    but I cant able to pick the files from FTP server.
    anyone have faced similar issues kindly let me know.
    Thanks
    Gowrishankar

    Hi,
    try this way..
    for reading the file using FTP you need to use different unix command ..
    Prabhuda

  • Error in Reading the file from Application Server

    Hi,
    This Error is regarding one of my interface, the issue is that , the interface reads data from file in bunch suppose 100 records at a time , then processes those records and once finished go for next 100 records .
    Noe the error is that , the process takes place till 500 records correctly but when it went to fetch for next 100 i.e fom 501 to 600 it selects only 501 to 583 .
    this records has been processed successfully but the job finished there only
    but the file contains 788 records
    When the same file has been run in other server it ran successfully without such error .
    Can you please suggest how to resolve the issue

    Hi,
    Try to manually download the file from application server using standard transactions, and than check how many records are you able to download from app. server.
    I guess there might be something wrong with the format of 583rd record, which makes sap assume that the file has come to an end.
    Hope this will help you.
    Regards,
    Vinit...

  • 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

  • How to read the file from ftp server

    Hi
    I need to read a file from a ftp server . Iam using apache lib common-net .jar .
    FTPClient ftp = new FTPClient();
    ftp.connect(server);
    ftp.login(username,password);
    FTPFile[] files = ftp.listFiles();
    for(int i=0 ;i<files.length;i++){
    System.out.println(" File : "+ i + " - " + files);     
    InputStream ip = ftp.retrieveFileStream(path);
    I got the inputstream from the ftp server. but iam not able to read the contents of the file ....
    help me plzzzzz

    Hi
    I have one more problem . first i try to read the file and write the file in local directory . then i try to read the data in the remote file .. iam getting the datas as null.
    InputStream ip = ftp.retrieveFileStream(path);                    
    File f = new File("D:\\ftp.txt");                    
    FileOutputStream fo = new FileOutputStream(f);
    byte[] buf = new byte[1024];
    while ((len = ip.read(buf)) > 0) {                         
    fo.write(buf,0,len);               
    fo.close();
    BufferedReader br = new BufferedReader(new InputStreamReader(ip));
    String line;
    do {
    line = br.readLine();
    System.out.println(" data " +line);
    }while (line != null);

  • How to convert JPG image to BMP ? (Printing jpg images in smartforms from content server)

    Hi,
    We have employee photos(JPG Format) stored in Content server. And now we want to print the photos in smartforms. For this I had written the below code to read the photo from content server in binary format as below.
    REPORT ZTEST1.
    PARAMETERS P_PERNR TYPE PERNR_D.
    DATA: PS_CONNECT_INFO TYPE TOAV0,
          IT_BINARY TYPE TABLE OF SDOKCNTBIN.
    CALL FUNCTION 'HR_IMAGE_EXISTS'
      EXPORTING
        P_PERNR                     = P_PERNR
    *   P_TCLAS                     = 'A'
    *   P_BEGDA                     = '18000101'
    *   P_ENDDA                     = '99991231'
    IMPORTING
    *   P_EXISTS                    =
       P_CONNECT_INFO              = PS_CONNECT_INFO
    * EXCEPTIONS
    * ERROR_CONNECTIONTABLE       = 1
    *   OTHERS                      = 2
    IF SY-SUBRC <> 0.
    * Implement suitable error handling here
    ENDIF.
    IF PS_CONNECT_INFO IS NOT INITIAL.
      CALL FUNCTION 'SCMS_DOC_READ'
        EXPORTING
       STOR_CAT                    = SPACE
       CREP_ID                     = PS_CONNECT_INFO-ARCHIV_ID
          DOC_ID                      = PS_CONNECT_INFO-ARC_DOC_ID
    *   PHIO_ID                     =
    *   SIGNATURE                   = 'X'
    *   SECURITY                    = ' '
    *   NO_CACHE                    = ' '
    *   RAW_MODE                    = ' '
    * IMPORTING
    *   FROM_CACHE                  =
    *   CREA_TIME                   =
    *   CREA_DATE                   =
    *   CHNG_TIME                   =
    *   CHNG_DATE                   =
    *   STATUS                      =
    *   DOC_PROT                    =
    TABLES
    *   ACCESS_INFO                 =
    *   CONTENT_TXT                 =
       CONTENT_BIN                 = IT_BINARY
    * EXCEPTIONS
    * BAD_STORAGE_TYPE            = 1
    *   BAD_REQUEST                 = 2
    *   UNAUTHORIZED                = 3
    * COMP_NOT_FOUND              = 4
    *   NOT_FOUND                   = 5
    *   FORBIDDEN                   = 6
    *   CONFLICT                    = 7
    * INTERNAL_SERVER_ERROR       = 8
    *   ERROR_HTTP                  = 9
    * ERROR_SIGNATURE             = 10
    *   ERROR_CONFIG                = 11
    *   ERROR_FORMAT                = 12
    * ERROR_PARAMETER             = 13
    *   ERROR                       = 14
    *   OTHERS                      = 15
      IF SY-SUBRC <> 0.
    * Implement suitable error handling here
      ENDIF.
    ENDIF
    Now the issue is I want to convert that binary data to bitmap image and upload the same in to SE78. So that I can use that BMP image from SE78 in my smartforms.
    I had used the class CL_IGS_IMAGE_CONVERTER to covert the image into bmp but it is giving error that error in IMAGE DATA CORRUPT & Error Code 3. The conversion code used is as below.
    ******* CONVERT THE JPG IMAGE INTO BMP PHOTO. **********
      DATA: L_IGS_IMGCONV TYPE REF TO CL_IGS_IMAGE_CONVERTER,
    L_IMG_BLOB    TYPE W3MIMETABTYPE,
    L_IMG_SIZE    TYPE W3PARAM-CONT_LEN,
    L_IMG_TYPE    TYPE W3PARAM-CONT_TYPE,
             L_IMG_SUBTYPE TYPE W3PARAM-CONT_TYPE,
    L_IMG_URL     TYPE W3URL,
    L_ERR_CODE    TYPE I,
    L_ERR_TEXT    TYPE STRING,
             P_DEST TYPE CHAR32 VALUE 'IGS_RFC_DEST'.
      DATA: G_IMG_BLOB     TYPE W3MIMETABTYPE,
          G_IMG_TYPE     TYPE W3PARAM-CONT_TYPE,
          G_IMG_SIZE     TYPE W3PARAM-CONT_LEN.
      IF NOT IT_BINARY[] IS INITIAL.
        G_IMG_BLOB[] = IT_BINARY.
        CREATE OBJECT L_IGS_IMGCONV
          EXPORTING
            DESTINATION = P_DEST.
        CALL METHOD L_IGS_IMGCONV->SET_IMAGE
          EXPORTING
            BLOB      = G_IMG_BLOB
            BLOB_SIZE = G_IMG_SIZE.
        CASE PS_CONNECT_INFO-RESERVE.
          WHEN 'TIF'.
            G_IMG_TYPE = 'image/tiff'.
          WHEN 'JPG'.
            G_IMG_TYPE = 'image/jpeg'.
          WHEN 'PNG'.
            G_IMG_TYPE = 'image/png'.
          WHEN 'GIF'.
            G_IMG_TYPE = 'image/gif'.
          WHEN 'BMP'.
            G_IMG_TYPE = 'image/x-ms-bmp'.
          WHEN OTHERS.
            EXIT.
        ENDCASE.
    L_IGS_IMGCONV->INPUT  = G_IMG_TYPE.
        L_IGS_IMGCONV->OUTPUT = 'image/x-ms-bmp'.
    *    PERFORM GET_SIZE USING PICTURE_CONTAINER
    * L_IGS_IMGCONV->WIDTH
    * L_IGS_IMGCONV->HEIGHT.
        CALL METHOD L_IGS_IMGCONV->EXECUTE
          EXCEPTIONS
            OTHERS = 1.
        IF SY-SUBRC IS INITIAL.
          CALL METHOD L_IGS_IMGCONV->GET_IMAGE
            IMPORTING
              BLOB      = L_IMG_BLOB
              BLOB_SIZE = L_IMG_SIZE
              BLOB_TYPE = L_IMG_TYPE.
          SPLIT L_IMG_TYPE AT '/' INTO L_IMG_TYPE L_IMG_SUBTYPE.
        ELSE.
          CALL METHOD L_IGS_IMGCONV->GET_ERROR
            IMPORTING
              NUMBER  = L_ERR_CODE
              MESSAGE = L_ERR_TEXT.
          BREAK-POINT.
        ENDIF.
      ENDIF.
    ENDIF.
    So could you please some one help me how to convert JPEG Photo to BMP programatically.
    Regards,
    Mayur.

    johnandersonpalmdesert wrote:
    My printer is requesting a vector file.
    Jpeg File format does not support vectors.  Photoshop has limited vector support and tools.  Photoshop can not save vector file formats like SVG.  What File type does your printer want?
    Adobe Illustrator is Adobe vector application.

  • How to Read the Image in SQL server

    I want to read the image from SQL server using labview.In our project languages used are JAVA and Labview
    Through java we acquiring the image and write in to SQL Server.
    Through Labview I want to read the image form SQL server and i will do some image processing for my application.
    My problem when I seen the database the images shown like hex decimal value.
    I want to convert the hexadecimal value to image or any other functions is there to directly read the image from SQL server.
    Can anybody help me....

    two options:
    1. save the image data itself (as a blob)
    2. save the image in a file system and save the file name in the DB

  • Copy the data from Sql Server to edirectory using java

    Hi ,
    I am new to e directory.I don't know how it works.Can some one assist
    me on this ,I have to extract data from SQL Server and update these
    data in edirectory.This is needs to be done using java.
    If any one can provide me the sample code or please suggest how to
    proceed .
    Thanks in advance
    dukewarm
    dukewarm's Profile: http://forums.novell.com/member.php?userid=53430
    View this thread: http://forums.novell.com/showthread.php?t=373051

    dukewarm;1792481 Wrote:
    > Hi ,
    >
    > I am new to e directory.I don't know how it works.Can some one assist
    > me on this ,I have to extract data from SQL Server and update these
    > data in edirectory.This is needs to be done using java.
    >
    > If any one can provide me the sample code or please suggest how to
    > proceed .
    >
    > Thanks in advance
    Read the values from SQL server and use LDAP to update the data in
    eDirectory.
    Thomas
    thsundel
    thsundel's Profile: http://forums.novell.com/member.php?userid=128
    View this thread: http://forums.novell.com/showthread.php?t=373051

  • Reading the data from excel file which is in application server.

    Hi,
    Iam trying to read the data from excel file which is in application server.
    I tried using the function module ALSM_EXCEL_TO_INTERNAL_TABLE. But it didn't work.
    I tried just reading using open data set and read data set it is giving junk characters.
    Please suggest me if you have any solution.
    Best Regards,
    Brahma Reddy

    Hi Narendra,
    Please see the below code I have written
    OPEN DATASET pa_sfile for INPUT in text mode ENCODING  DEFAULT MESSAGE wf_mess.
    CHECK sy-subrc = 0.
    DO.
    READ DATASET pa_sfile INTO wf_string.
    IF sy-subrc <> 0.
    EXIT.
    else.
    split wf_string at wl_# into wf_field1 wf_field2 wa_upload-field3
    wa_upload-field4 wa_upload-field5 wa_upload-field6 wa_upload-field7 wa_upload-field8
    wa_upload-field9 wa_upload-field10 wa_upload-field11 wa_upload-field12 wa_upload-field13
    wa_upload-field14 wa_upload-field15 wa_upload-field16 wa_upload-field17 wa_upload-field18
    wa_upload-field19 wa_upload-field20 wa_upload-field21 wa_upload-field22 wa_upload-field23
    wa_upload-field24 wa_upload-field25 wa_upload-field26 wa_upload-field27 wa_upload-field28
    wa_upload-field29 wa_upload-field30 wa_upload-field31 wa_upload-field32 wa_upload-field33
    wa_upload-field34 wa_upload-field35 wa_upload-field36 .
    wa_upload-field1 = wf_field1.
    wa_upload-field2 = wf_field2.
    append wa_upload to int_upload.
    clear wa_upload.
    ENDIF.
    ENDDO.
    CLOSE DATASET pa_sfile.
    Please note Iam using ECC5.0 and it is not allowing me to declare wl_# as x as in your code.
    Also if Iam using text mode I should use extension encoding etc.( Where as not in your case).
    Please suggest me any other way.
    Thanks for your help,
    Brahma Reddy

  • What are the commands available to read a file from application server and

    What are the commands available to read a file from application server and store the file into an internal table?

    Hi,
    To read a file from an Application Server to an Object there is a command in ABAP called <b>READ DATASET</b>. After that file is transported to that object you have to do a loop and put that data in an Internal Table.
    This statement exports data from the file specified in dset into the data object dobj. For dobj, variables with elementary data types and flat structures can be specified. In Unicode programs, dobj must be character-type if the file was opened as a text file.
    For dset, a character-type data object is expected - that is, an object that contains the platform-specific name of the file. The content is read from the file starting from the current file pointer. After the data transfer, the file pointer is positioned after the section that was read. Using the MAXIMUM LENGTH addition, the number of characters or bytes to be read from the file can be limited. Using ACTUAL LENGTH, the number of characters or bytes actually used can be determined.
    In a Unicode program, the file must be opened with an arbitrary access type; otherwise, an exception that cannot be handled will be triggered.
    If the file has not yet been opened in anon-Unicode program, it will be implicitly opened as a binary file for read access using the statement
    OPEN DATASET dset FOR INPUT IN BINARY MODE.
    . If a non-existing file is accessed, an exception that can be handled can be triggered.
    Influence of Access Type
    Files can be read independently of the access type. Whether data can be read or not depends solely on the position of the file pointer. If the latter is at the end of the file or after the file, no data can be read and sy-subrc will be set to 4.
    Influence of the Storage Type
    The import function will take place irrespective of the storage type in which the file was opened with the statement OPEN DATASET.
    If the file was opened as a text file or as a legacy text file, the data is normally read from the current position of the file pointer to the next end-of-line marking, and the file pointer is positioned after the end-of-line marking. If the data object dobj is too short for the number of read characters, the superfluous characters and bytes are cut off. If it is longer, it will be filled with blanks to the right.
    If the file was opened as a binary file or as a legacy-binary file, as much data is read that fits into the data object dobj. If the data object dobj is longer than the number of exported characters, it is filled with hexadecimal 0 on the right.
    If the specified storage type makes conversion necessary, this is executed before the assignment to the data object dobj. Afterwards, the read data is placed, byte by byte, into the data object.
    System Fields
    sy-subrc Meaning
    0 Data was read without reaching end of file.
    4 Data was read and the end of the file was reached or there was an attempt to read after the end of the file.
    Thanks,
    Samantak.
    <b>Rewards points for useful answers.</b>

  • Problem in reading the excel file path in WINDOWs machine from UNIX environ

    Hello friends,
    My requirement is to read each row of the excel sheet and sent that row to the database. I have implemented it by using jxl and apache poi framework. locally in my WINDOWS machine it is working fine..
    But when i deploy the code in UNIX machine. My application runs on a Unix server , trying to read the excel file in WINDOWS environment. I am not able to retrieve the file path. for ex : C:\Documents and Settings\sabbanik\My Documents\KARUNAKAR\excel.xls
    I am getting error in this line
    workbook = Workbook.getWorkbook(filepath)
    Error message : input file not found.
    Thanks in advance..

    You said: I am getting error in this line workbook = Workbook.getWorkbook(filepath) >
    Based on this, I will assume you are trying to use OLE to access information about the Excel file. As mentioned by Andreas, your code will be executing on the server (Unix) and since Excel isn't on the server (and cannot be) an error will result. OLE can only be used in Windows environments (client or server). To access client side OLE calls and content, you need a java bean and Excel installed on the client machine. Oracle provides WebUtil as an option to writing your own Java Bean. To use this, you will need to be running Forms 10.1.2 or newer. Details can be found here along with a demo:
    http://www.oracle.com/technetwork/developer-tools/forms/webutil-090641.htm

  • How to read the data from Excel file and Store in XML file using java

    Hi All,
    I got a problem with Excel file.
    My problem is how to read the data from Excel file and Store in XML file using java excel api.
    For getting the data from Excel file what are all the steps i need to follow to get the correct result.
    Any body can send me the code (with java code ,Excel sheet) to this mail id : [email protected]
    Thanks & Regards,
    Sreenu,
    [email protected],
    india,

    If you want someone to do your work, please have the courtesy to provide payment.
    http://www.rentacoder.com

  • Automation prog for placing the file( Excel) From production server to unix

    Hi Experts,
    How to write a program to automate a file from production to unix server?
    Right now user is downloading the file from application server and sending the file thru mail. 
    Is it possible in ABAP or Do we need to write in Unix?
    Thanks In Advance.
    Regards,
    sridhar

    Please see old threads for similar discussion -- http://forums.oracle.com/forums/search.jspa?threadID=&q=Shell+AND+Script+AND+FTP&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001
    Thanks,
    Hussein

Maybe you are looking for