scratch notes on aws exacting the last field!
echo “ABC.123.QIP.ERR” | awk -F. {’print $(NF-0)’}
- dot after F is the field deliminator
- minus zero is the field to extract from backwards of the string
echo “ABC.123.QIP.ERR” | awk -F. {’print $(NF-0)’}
- dot after F is the field deliminator
- minus zero is the field to extract from backwards of the string
No comments:
Post a Comment