469,898 Members | 1,675 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,898 developers. It's quick & easy.

strange replacement of . and , with octal counterpart

The following code produces fine result when everything is hard wired
but replaces '.' and ',' with there octal counterparts when the
variables are passed to it. Can't figure out why. I would appreciate
if anyone could shed some light to the darkness.

hard wired

Passed variables


open DATA, "/usr/local/data/mra/archive/${pid}Diagnosis.dat"
or die "Can't open this file!";

open REMINDER, ">>/usr/local/data/mra/archive/${pid}Reminder.dat"
or die "Can't open this file !";

open CHRONIC, ">>/usr/local/data/mra/archive/${pid}Chronic.dat"
or die "Can't open this file !";

open ACUTE, ">>/usr/local/data/mra/archive/${pid}Acute.dat"
or die "Can't open this file !";

while ($line = <DATA>){
= split("~",$line);
if ($reminder_flag =~1) {
if ($priority_flag =~1) {
print REMINDER $line;
} else {
print CHRONIC $line;
} else {
if ($priority_flag =~1) {
print CHRONIC $line;
} else {
print ACUTE $line;
close DATA;
close CHRONIC;
close ACUTE;
Jul 19 '05 #1
0 1268

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

28 posts views Thread by Erik Johnson | last post: by
20 posts views Thread by Sean McIlroy | last post: by
6 posts views Thread by WindAndWaves | last post: by
27 posts views Thread by fuch6921 | last post: by
5 posts views Thread by joe.hrbek | last post: by
7 posts views Thread by Gary Brown | last post: by
10 posts views Thread by laurent.pauloin | last post: by
25 posts views Thread by notahipee | last post: by
1 post views Thread by Waqarahmed | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.