thanks. I wasn't aware of the rename function. As far as converting to YYYYMMDD, can that be done on the fly using localtime()? I am reading online docs now, but nothing talks about it done on the fly i.e. when I call the function up. If not I will work on it some more and follow up with whatever I find out. Regards.
Wiggins d Anconia <[EMAIL PROTECTED]> wrote: > jason corbett wrote: > > How can i rename a file or create a file with the date included? For > > example, I want to automate and run reports and save the reports > > under the date of when they were created i.e. JC07082004. Whats the > > easiest way to do this? > > > > Thanks, > > JC > > Using localtime in conjunction with time, you can roll your own little setup. > Additionally, if you didn't know already, Perl has a 'rename' function built in, or if you are going to g across file system boundaries you should look at the File::Copy module. perldoc -f rename perldoc -f time perldoc -f localtime perldoc File::Copy Additionally you might consider using the Compress::Zlib for compression of the logs, and you should definitely consider changing your naming convention to be YYYYMMDD as that will allow the files to sort properly in their directory. http://danconia.org -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]