Process Chain - Delete File from Application Server

Hi Gurus,
Im working with Process chain, and i have a load from a flat file, so my question is :
How can i delete that file from the application server after was loaded ?
THANKS IN ADVANCED !!! I REALLY APRECCIATE YOUR HELP.
Marcos

hi,
I have gone through the forum you have posted for deleting files from application server through process chain.
I have similar reuirement in my project.
Can you please provide me the solution?
Your inputs will be highly appreciated.
Thanks in advance.
Regards,
Lavanya.

Similar Messages

  • Deleting file from application server

    can any one tell me how to delete file from application server?

    Hi,
      Use statement
      delete dataset 'tmpfile.txt'.
    \tmp\file.txt is the file path on application server which you want to delete.
    Regards
    Sailaja.

  • T-code for delete file from application server

    Hi all!
    Please, has any t-code for delete file from application server? For upload exist CG3Z, for download has CG3Y. And for delete? Has anyone?
    I need to delete file from application server in QA system and i don't want to create a program for this because i will need to transport a request from DEV to QA.

    I don't have contact with basis team.
    The FM EPS_DELETE_FILE support directory name with max 60 char. My dir. has more than that. I need a transaction for this.
    Anybody know if this transaction exist?

  • How to delete file from application server(Unix)

    Hi All,
    Using the below code downloading a file from application server(Unix) to client machine. I want to delete the file from application server once it is downloaded to client
    We work on Forms 11.1.1.4.0 and Oracle DB 10g. Client machine are Windows 7.
    BEGIN
      IF webutil_file_transfer.AS_to_Client
      (clientFile => Name_In('global.g_file_name')
      ,serverFile => ls_AppServer_Loc)THEN
      message('Data exported Successfully');
      ELSE
       message('File download from Application Server failed');
      END IF;
    EXCEPTION
      WHEN OTHERS THEN
      message('File download failed: '||SUBSTR(sqlerrm,1,200));
      END;
    I have search for solution on OTN. Few suggested to use HOST.
    Can any one help me how to use Host() built_in to delete the file.
    Thanks,
    Maddy

    Can any one help me how to use Host() built_in to delete the file.
    Host('/bin/rm <complete file path>');

  • Delete file from application server

    Hi,
       Can any one tell me how to delete a file from application server?
    Thanks,
    Rahul.

    Basic question, please search for available information.
    Thread locked.
    Thomas

  • How to delete files from application server posted in last 30 days

    I have some files in application server posted through ABAP program with the below format
    \.\.\.abcd_20110209_111209.csv   (with  date and time). I need to delete those files which was posted in last 30 days through another program. Could you plaese help me to achieve the requirement?

    There are many ways you can delete/archive files in application servers.
    1. Depending on the application server, usually administrators setup delete/archive programs. For e.g. if the application server is a UNIX, then the unix admin will write a script to delete/move older files. - this is the most common approach I've seen.
    If you have to achieve this through ABAP then,
    1. You can get the script from the server admin and then use that script to create an external system command through SM69/49 and use the function module SXPG_COMMAND_EXECUTE to execute it.
    2. You can also look at FM EPS_DELETE_FILE and see if it fits the bill for you.
    There are many other possibilities too and each one has its own pros/cons. So you'll have to choose the right one for your requirement.

  • Delete files from APPLICATION SERVER?

    Hi All,
    I am creating the files in application server with folder name as
    /interface/freeway/ and filename as PO concatenating with sy-datum and sy-uzeit.
    Ex file name now is /interface/freeway/PO20081201064120.csv
    Now my req is i need to delete files which has beeen created less than 30 days.
    regards,
    Sachin.

    hi,,,,,,
    REPORT ZDELETE.
    * Delete a file on the application server.
    PARAMETERS: P_DIR LIKE RLGRAP-FILENAME
    DEFAULT '/usr/sap/trans/',
    P_FILE1 LIKE RLGRAP-FILENAME.
    DATA: P_FILE(128).
    DATA: W_ANS.
    START-OF-SELECTION.
    CONCATENATE P_DIR P_FILE1 INTO P_FILE.
    * check file exists
    OPEN DATASET P_FILE FOR INPUT.
    IF SY-SUBRC NE 0.
    MESSAGE E899(BD) WITH P_FILE 'does not exist'.
    EXIT.
    ELSE.
    CALL FUNCTION 'POPUP_CONTINUE_YES_NO'
    EXPORTING
    DEFAULTOPTION = 'N'
    TEXTLINE1 = P_DIR
    TEXTLINE2 = P_FILE1
    TITEL = 'ARE YOU SURE YOU WANT TO DELETE'
    * START_COLUMN = 25
    * START_ROW = 6
    IMPORTING
    ANSWER = W_ANS
    EXCEPTIONS
    OTHERS = 1.
    ENDIF.
    CLOSE DATASET P_FILE.
    CHECK W_ANS = 'J'.
    * delete
    DELETE DATASET P_FILE.
    IF SY-SUBRC NE 0.
    MESSAGE E899(BD) WITH 'Invalid file name' P_FILE.
    ELSE.
    CLOSE DATASET P_FILE.
    MESSAGE I899(BD) WITH P_DIR P_FILE1 'DELETED'.
    ENDIF.

  • Process Chain - Transfering Files to Application Server

    Hi guys,
    I have been trying to use BW Process Chain to load data from a flat file (CSV) into an InfoCube.
    I understand for it to work, the file has to reside on the Application Server, and not the local workstation.
    However, can anyone tell me exactly how I can transfer the flat file from my laptop into the Application Server?
    Thanks!
    SJ

    Thanks Edwin!
    The link is a nice introduction. But I'm still facing some issues. Here's a simple scenario:
    I try to upload a file from the path "C:\BW_CSV\Month.csv". I go to transaction FILE and did the following settings.
    1. Logical file path definition:
        a.   Created a new entry called "ZBW_CSV"
    2. Assignments of physical path:
        a.   Syntax Group: Windows NT
        b.  
    Leopard01\BW_CSV\<FILENAME>
    Note: Leopard01 is the server name.
    3. Logical file name definition:
        a.   Created a new entry called "ZBW_CSV"
        b.   Physical file: Month.csv
        c.   Data format: BIN
        d.   Application area: BW
        e.   Logical path: ZBW_CSV
    After all this, when I try to preview the file from the infopackage, I still get an error message -- "Error 8 when compiling the upload program".
    I wonder what settings are not properly configured. Please advise.

  • Urgent : Download file from Application Server via Process Chain.

    Hi Experts,
    My requirement is to download the file from Application Server to local work station using an ABAP Program .
    I want including the above ABAP program in a process chain to execute  the program daily,
    I tried to use ARCHIVFILE_SERVER_TO_CLIENT and GUI_DOWNLOAD but unfortunately both the above FM doesn't support to run through Process chain.
    Can any one of you help me to send the code which selects a file from application server, downloads to local system and deletes it.
    Thank you very much for spending your precious time in this regard.

    Hi Sailekha,
    Regarding your case ..
    I suggest you to create the program where it run this function: WS_DOWNLOAD.
    After it, the program is run by your process chain.
    Hopefully it can help you a lot.
    Regards,
    Niel.
    thanks for the points you choose to assign.

  • File from application server -Read and process and delete the file .

    Hi All,
             I writing a ZEE program which will read the file from application server(file will be in text delimat format) and moving the data to internal table and uploadind data base.The part which iam facing problem is -
    > I hve read the file from application server like below ,
    OPEN DATASET ld_file FOR INPUT IN TEXT MODE ENCODING DEFAULT.
    IF sy-subrc NE 0.
    EXIT.
    ELSE.
      DO.
        CLEAR: wa_string, wa_uploadtxt.
        READ DATASET ld_file INTO wa_string.
        IF sy-subrc NE 0.
          EXIT.
        ELSE.
          SPLIT wa_string AT con_tab INTO wa_uploadtxt-name1
                                          wa_uploadtxt-name2
                                          wa_uploadtxt-age.
    Spliting part i having problem .i need to seperate each field which is seperate from tab delimite and pass it into respective fields of internal table .
    Second if another file come to the appicaltion server , wether my first file will be there ? or should i need to delete the first file after redaing how should i proceed further ?.
    Regards
    SRIRAM...
    THANKS In ADVANCE

    HI,
    1.
    OPEN DATASET ld_file FOR INPUT IN TEXT MODE ENCODING DEFAULT.
    IF sy-subrc NE 0.
    EXIT.
    ELSE.
    DO.
    CLEAR: wa_string, wa_uploadtxt.
    READ DATASET ld_file INTO wa_string.
    IF sy-subrc NE 0.
    EXIT.
    ELSE.
    SPLIT wa_string AT cl_abap_char_utilities=>horizontal_tab INTO wa_uploadtxt-name1
    wa_uploadtxt-name2
    wa_uploadtxt-age.
    APPEND  wa_uploadtxt TO itab.
    ENDDO.
    CLOSE DATASET ld_file.
    ENDIF.
    2. If the another file get's generated in the application server with same file name then the data in old file get's over written with the new data. You are not required to delete the file.

  • How to delete the Generated files from application server(open hub)?

    hi experts,
    when i try to execute process chain the DTP it is giving below dump. Exception CX_RSBK_REQUEST_LOCKED logged.
    when i execute the DTP manually and trying to delete the previous request, it is giving for dump ITAB_DUPLICATE_KEY.
    so to delete the generated file from application server, how to delete it for specific dates?
    Information on where terminated
    Termination occurred in the ABAP program "GPD6S3OE0BCVGC6L9DBNVYQARZM" - in
    "START_ROUTINE".
    The main program was "RSBATCH_EXECUTE_PROZESS ".
    In the source code you have the termination point in line 2874
    of the (Include) program "GPD6S3OE0BCVGC6L9DBNVYQARZM".
    The program "GPD6S3OE0BCVGC6L9DBNVYQARZM" was started as a background job.
    and when i check the dump it is point out at below code
    " Populate the lookup table for 0STOR_LOC
    SELECT * from /BI0/TSTOR_LOC
    into CORRESPONDING FIELDS OF table L_0STOR_LOC_TEXT
    FOR ALL ENTRIES IN SOURCE_PACKAGE WHERE
    STOR_LOC = SOURCE_PACKAGE-STOR_LOC.
    but the programme is syntactically correct only.
    how to rectify the issue.
    regards
    venuscm
    Edited by: venugopal vadlamudi on Sep 28, 2010 1:59 PM

    hi experts,
    We have written start routine to get the storage location text and sending to File located at Application server through OPEN HUB.
    here is the code written in the Transformations
    In the global section
    Text for 0STOR_LOC
        DATA: l_0stor_loc_text TYPE HASHED TABLE OF /bi0/tstor_loc
              WITH UNIQUE KEY stor_loc.
        DATA: l_0stor_loc_text_wa TYPE /bi0/tstor_loc.
    and in the code to get the text
    " Populate the lookup table for 0STOR_LOC
        *SELECT * from /BI0/TSTOR_LOC*
          into CORRESPONDING FIELDS OF table L_0STOR_LOC_TEXT
          FOR ALL ENTRIES IN SOURCE_PACKAGE WHERE
                  STOR_LOC = SOURCE_PACKAGE-STOR_LOC.
    im sure there is problem with the Routine only. i think i need to change the code if so please provide me the modified one.
    thanks
    venuscm
    Edited by: venugopal vadlamudi on Sep 29, 2010 9:37 AM

  • How to delete a file from application server?

    Hi gurus,
    i want delete a file from application server . can any one tell me the BAPI/Fm .
    thanks in advance

    See the replies of the thread;
    How to delete  File from the Application Server,ABAP
    But i can smell something fishy in both  The specified item was not found. and The specified item was not found. style of posting questions. Also both of you have similar questions in your profile....
    Hmmm, Mods have to take care of the Rest...
    Regards
    Karthik D

  • Move file to application server  or delete a file from application server

    Hi all
    I have one application in which if succeful uploading  of BMP file  from application server is not  done , File has to move to another folder like 'ERROR' Folder
    but i am unable to do that.
    here is the code:
    CONDENSE g_t_ws_move.
    CALL 'SYSTEM' ID 'COMMAND' FIELD g_t_ws_move
      ID 'TAB'     FIELD g_t_ws_command_line[].
    where
    <b>G_T_WS_MOVE= 'MOVE /Y /sapin/XVZ/journeyplan/0000000.BMP /tmp/0000000.BMP'
    means  i have to move 000000.bmp file from XVZ to tmp directory ,</b>

    Hello Neetu
    Alternatively you could use a combination of the following function modules:
    - EPS_FTP_PUT
    - EPS_DELETE_FILE
    Regards
      Uwe

  • Problem in uploading file from Application Server

    Hi everyone,
    i got a problem in uplaoding a file from application server.i am having two folder (one folder name is current and another one is processed)in application server. In current folder i am having N no of files.I want to upload all the files names into one internal table and i want to process one by one file.After processing each file the file should be moved to processed folder and the files should not exist in current folder.All these process must be done everyday.Please rectify my problem asap.

    Ramesh,
    Take authorization from basis guy.
    Use the below code to get the list of files from require directory
    *& Report  ZDIRFILES                                                   *
    REPORT  ZDIRFILES    .
    PARAMETER: p_fdir            type pfeflnamel DEFAULT '/usr/sap/tmp'.
    data: begin of it_filedir occurs 10.
            include structure salfldir.
    data: end of it_filedir.
    *START-OF-SELECTION
    START-OF-SELECTION.
    Get Current Directory Listing for OUT Dir
      call function 'RZL_READ_DIR_LOCAL'
           exporting
                name     = p_fdir
           tables
                file_tbl = it_filedir.
    Now in internal table "it_filedir"  will have all your files.
    For moving and deleting
    report zrich_0001.
    Parameters: d1 type localfile default '/usr/sap/TST/SYS/fld1/Data1.txt',
                d2 type localfile default '/usr/sap/TST/SYS/fld2/Data1.txt'.
    data: begin of itab occurs 0,
          rec(20) type c,
          end of itab.
    data: wa(20) type c.
    start-of-selection.
      open dataset d1 for input in text mode.
      if sy-subrc = 0.
        do.
          read dataset d1 into wa.
          if sy-subrc <> 0.
            exit.
          endif.
          itab-rec = wa.
          append itab.
        enddo.
      endif.
      close dataset d1.
      open dataset d2 for output in text mode.
      loop at itab.
        transfer itab to d2.
      endloop.
      close dataset d2.
      delete dataset d1.
    Check below FM if required
    To move the file to archive directoryuse FMs 'PFL_COPY_OS_FILE'
    To Delete 'EPS_DELETE_FILE'.
    Don't forgot to reward if useful

  • How to transfer file from application server to presentation server in background?

    Hi Experts,
    How to transfer file from application server to presentation server in background?
    Thanks in advance
    Namita

    Thanks Raman and Challa,
    We want to move file from application server to Shared folder, not on local machine. We checked FM which you guys have provided but those are not able to read file from application server.
    We need this program to run in background so that we can use this in daily process chain.
    Appreciate your inputs on this.
    Thanks,
    Namita

Maybe you are looking for