Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

Re^5: Problem with ampersand and regex

by frozenwithjoy (Priest)
on Dec 19, 2012 at 21:18 UTC ( #1009637=note: print w/replies, xml ) Need Help??

in reply to Re^4: Problem with ampersand and regex
in thread Problem with ampersand and regex

What if you use backticks (`ldapsearch`) instead of system("ldapsearch"). When I put mail: in a file and called @array = `cat file`, your script worked, but not when using @array = system("cat file").

Take a look at What's the difference between Perl's backticks, system, and exec?. The system() call returns the exit status, not the actual result (STDOUT) of the command like the backtick operator does.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1009637]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2018-03-21 10:08 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (265 votes). Check out past polls.