
steve798
Novice
Nov 27, 2017, 2:05 PM
Post #1 of 2
(2976 views)
|
How to display the year/quarter information in a filename
|
Can't Post
|
|
I am writing out a csv file with filename format as region_YYYYMMDDHHMMSS with below declaratives. Example region_20171127112030.csv
my $date = UnixDate(($opts{'d'} || 'today'), '%q');
my $dumpdir = "$wkdir/region_$date.csv"; How could I make the file format show as region_YYYY-QTRX (where YYYY is the year and X is the quarter number like 1,2,3,4 ) ?? Example: region_2017-QTR3.csv
|