The following code snippet is throwing error if i use the mkpath command.Can any one help please?
i get the following error message:
D:\perl_prj>perl ex2.pl a.csv
mkdir IDS/CPIDS
: Invalid argument; The filename, directory name, or volume label syntax is incorrect at ex2.pl line 28
use File::Path;
#get file name from command line
$fname = @ARGV[0];
$vt = ht62_ucm;
$ucm_path='M:/ht62_ucm/GIS_COMP';
#open the file for reading
if (open FHR, "$fname")
{
foreach (<FHR>)
{
#print;
s/ //g;
@params = /[^,]+/g;
#create config spec file
if (open FHW, '>cs.txt')
{
print FHW "element * $params[1]\n" ;
print FHW "element * /main/LATEST\n";
$a=`cleartool setcs -tag $vt cs.txt`;
$FILE_SEARCH="$params[0]" . "\.sql";
our $fscript1=`cleartool find $ucm_path/$params[2] -version "lbtype_sub($params[1])" -name $FILE_SEARCH -print`;
@fscript2=split('@@', $fscript1);
print STDOUT "script name is $fscript2[0]";
$path_name = $params[2];
mkpath("$path_name");
}
else
{
print "write unsuccesful\n";
}
close ( FHW );
}
close ( FHR );
}
else
{
print "file open unsuccesful";
}