I need to write the this statement:
cat filename | awk -F '|' '($4 ~ /"$Var_PRJ"/) && ($7 == "Y")'.
However, $Var_PRJ is not getting expanded (may be because awk uses single quotes). How can I get this implemented with actual value of Var_PRJ?
Note: cat filename | awk -F '|' '($4 ~ /1234/) && ($7 == "Y")' is working fine.
 
     
    