old question : same problem
Jeff Hoffman
wonicon at optusnet.com.au
Mon Jan 8 23:19:42 CST 2007
At 07:35 AM 9/01/2007, you wrote:
Hi
Set up a batch queue that only allows one job at a time.
Just write a DCL script (submit to the above queue) to do a dir of the
receive directory which then moves all the files to a process directory and
submits each file to a standard script to the batch queue. The standard
script will run the program with the file (from the process directory using
a file equate) then transfer the file to a processed directory (if
successful). The original script will resubmit itself, which should run
again after all the files have been processed If there are no files to be
processed you might want to delay the resubmit for a period of time.
Net result is that unprocessed files will be in the receive dir, processed
files will be in the processed dir and any unprocessed or files with
problems will be in the process dir.
The main problem is how to stop processing of a file if the users has sent,
exactly the same data twice, with or without differing file names.
You may also want to append a date/time stamp in the file name when you
move the file to the process directory to facilitate identifying when files
where started processing.
Jeff
>Along time ago in a magazine far far away we found an article call CRON
>for VAX in VaxProfessional Magazine.
>I think this was 1987 if memory serves me correctly
>
>We manually entered that program in and created a CRON process to do
>just what you asked.
>It would wake up every minute and check if anything existed in a
>directory, if there was something it submitted a batch job with the file
>name it found.
>Sorry I do not have that utility around anymore, but somebody might have
>it.
>
>Ken
>
>
>-----Original Message-----
>From: powerh-l-bounces+ken.langendock=rogers.com at lists.sowder.com
>[mailto:powerh-l-bounces+ken.langendock=rogers.com at lists.sowder.com] On
>Behalf Of Etienne Rompré
>Sent: January 8, 2007 3:20 PM
>To: powerh-l at sowder.com
>Subject: old question : same problem
>
>
>Hi to all!
>
>It might be related to Powerhouse or not but I give it a shot!
>Tools availables
>PH 8.4 VMS
>Cobol on VMS
>OpenVms 7.3
>RMS file
>flat Text file
>
>The problem:
>A client send one or more text file via ftp.
>The name will always be different.
>I can't process the file 2 time.
>The FTP process can't rename the file to NATWRRN.TXT since there might
>be 2 files at the same time.
>
>Question:
>Is there a way in powerhouse or in VMS to know automaticaly when a file
>is written in a directory and be able to process that file by name? Or
>start a COM that could rename the file automaticaly when the file is
>written and then start a QTP to import the file with a fixed name?
>
>Thanks!
>
>Etienne Rompré
>Koala-Tech
>
>--
>= = = = = = = = = = = = = = = = = = = = = = = = = = = =
>Mailing list: powerh-l at lists.sowder.com
>Subscribe: "subscribe" in message body to
>powerh-l-request at lists.sowder.com
>Unsubscribe: "unsubscribe <password>" in message body to
>powerh-l-request at lists.sowder.com
>http://lists.sowder.com/mailman/listinfo/powerh-l
>This list is closed, thus to post to the list you must be a subscriber.
>Add 'site:lists.sowder.com powerh-l' to your search terms to search the
>list archive at Google.
>
>
>--
>= = = = = = = = = = = = = = = = = = = = = = = = = = = =
>Mailing list: powerh-l at lists.sowder.com
>Subscribe: "subscribe" in message body to
>powerh-l-request at lists.sowder.com
>Unsubscribe: "unsubscribe <password>" in message body to
>powerh-l-request at lists.sowder.com
>http://lists.sowder.com/mailman/listinfo/powerh-l
>This list is closed, thus to post to the list you must be a subscriber.
>Add 'site:lists.sowder.com powerh-l' to your search terms to search the
>list archive at Google.
More information about the powerh-l
mailing list