perl linux command not working -


cat t.incopt.02.20110221 | awk -f, '{print $1}' | sort | uniq 

got unque records

but if inserted perl,

@fetch_req_details = `cat t.incopt.02.20110221 | awk -f\, '{print $1}' \| sort \| uniq`; 

if print above array vari, getting entire file content, guess linux command not working correctly when use inside perl,

i think need enclose command in tick , escape $

@fetch_req_details = `cat t.incopt.02.20110221 | awk -f, '{print \$1}' | sort | uniq;` 

Comments

Popular posts from this blog

linux - Mailx and Gmail nss config dir -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -