S
Sukhbir Dhillon
Hi! I'm trying to split the string from some file with | (pipe) seperated.
heres one of the string lines from data file.
Sukhbir Dhillon|[email protected]|data.txt|Thank you|student|
I'm using following code to read and split
open (READ_DB, "$dbfile");
while (<READ_DB>)
{
$_ =~ tr/A-Z/a-z/;
($name, $value, $filename, $message, $position) = split(/\|/);
close(READ_DB);
and I found that $position is getting undef value and which gives lots of error mentioned in the subject.
I'm pretty new in perl so please excuse my ignorance.
Thank you
Sukhbir
heres one of the string lines from data file.
Sukhbir Dhillon|[email protected]|data.txt|Thank you|student|
I'm using following code to read and split
open (READ_DB, "$dbfile");
while (<READ_DB>)
{
$_ =~ tr/A-Z/a-z/;
($name, $value, $filename, $message, $position) = split(/\|/);
close(READ_DB);
and I found that $position is getting undef value and which gives lots of error mentioned in the subject.
I'm pretty new in perl so please excuse my ignorance.
Thank you
Sukhbir