|
|
| Perl-Sensitive Sunglasses | |
| PerlMonks |
Re: how to use perl variable in system command to run on unixby toolic (Bishop) |
| on Sep 03, 2013 at 16:36 UTC ( [id://1052141]=note: print w/replies, xml ) | Need Help?? |
|
q prevents variable interpolation. So, $grep_date is not taking on the value 'Sep 02' inside your system call. It remains the literal string $grep_date. Try something like:
Also, system returns an exit status, not a command output. Look at qx.
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||||||||||||