in reply to Re: variable mixing numbers,characters & scalers
in thread variable mixing numbers,characters & scalers
Basically the script is prompting you for a date of a report you want. The problem is is that the report name is always Myyyymmdd#### (# meaning any number) I need the code to be able take the date the user puts in and match that up with the file it finds and add the last 4 digits that are in the file name#!/usr/bin/perl -w print "Post Production Report program \n"; print "Enter the Date (yyyymmdd) for the report: \n"; $date= <STDIN>; chomp ($date); print "Enter report type (d for detail or s for summary): \n"; $type= <STDIN>; chomp ($type); if ($type =~ /^d\b/) { $reptr=-detail } else { $reptr=-summary } $1=~[\d0-9]; $2=~[\d0-9]; $3=~[\d0-9]; $4=~[\d0-9]; system `cd /tivoli/maestro/schedlog`; $sched_log="M$date$1$2$3$4"; `conman "reptr $reptr $sched_log"`;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: variable mixing numbers,characters & scalers
by derby (Abbot) on Apr 01, 2002 at 18:45 UTC | |
by ddrumguy (Acolyte) on Apr 01, 2002 at 22:41 UTC |