hi,
please help as how i can do the following using perl.
there is a text file which contains the log details. once the textfile size crosses its maximum capacity, automatically it should create a next text file with the same name and starts using this new file.
Thanks,
banuruby
####################
hi,
use the stat function on the given file.
for example
@array = stat("file.txt");
this will return the various attributes of the file like read,write permission,file size in the @array
the 8 th element of the array is filesize.
then you can use the if-else loop to keep checking the file size and opening the next file for writting when the size exceeds the expected limit
let me know whether above solution solved your problem