I know how to do OR in awk
or sed
and grep
mathes lines regex1 or regex2 or regexp3
How do I match lines containing only regexp1 AND regexp2 AND regexp3
Thanks.
Code:
awk '/regexp1|regexp2|regexp3/{print}' filename
Code:
sed -n '/regexp1\|regexp2/\|regexp3/p' filename
Code:
grep "regex1\|regexp2" filename
How do I match lines containing only regexp1 AND regexp2 AND regexp3
Thanks.