× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



For IFS files, use RMVLNK command.

HTH



-----Original Message-----
From: Michael Lange [mailto:mfltek@xxxxxxxxxxxxxx]
Sent: Thursday, April 02, 2020 2:47 PM
To: midrange-l@xxxxxxxxxxxxxxxxxx
Subject: Deleting CSV from folder

V7.2


So I have this bit of code where we archive inbound CSV files before processing them.
The problem arises when somehow the same file gets pulled in and the archive fails because we already have it the second archive folder.


So I'm putting the MONMSG in and want to delete the CSV from the input folder but DLTOBJ doesn't like my OBJ.


How do I go about deleting the file?
There will only ever be one file in the folder.



/* Move previous files to Archive                             */
           MOV        OBJ('/home/linetec/input/*.csv') +        
                        TODIR('/home/linetec/archive')          
           Monmsg     MsgID(CPFA093)                            
           MONMSG     MSGID(CPFA0B8) EXEC(DO)                   
           MOV        OBJ('/home/linetec/input/*.csv') +        
                        TODIR('/home/linetec/archive/dup')      
        /* CPFA08E - More than one name matches pattern.   */   
           MONMSG     MSGID(CPFA08E) EXEC(DO)                   
            dltobj     obj('/home/linetec/input/*.CSV')         
           ENDDO                                                
           ENDDO                                                


Regards
Michael

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.