I've been learning how to work with z/VM through the zLinux console. I've sent a CMS command to a z/VM guest and had the output return to a file on zLinux. Now all that is left is to cleanup the file and extract the right date through a pattern.
I noticed that the file contains the right data between a { and a \. The pattern opens with a { and ends with a . See the example below.
Example:
&{HELLO WORLD TEST 123 \INMR06
There are many lines like these and I tried extracting the pattern using the commands:
awk -F"[{\]" '{print $2}' TMPCMSResult: HELLO WORLD TEST 123 \INMR06
awk -F"[{\\]" '{print $2}' TMPCMSResult: awk: warning: escape sequence
\]' treated as plain]'*HELLO WORLD TEST 123 \INMR06*
I would like to get only the string "HELLO WORLD TEST 123" between the { and \, and ignore "\INRM06".
I just don't seem to be able to escape that "\".
Yours truly,
Joeyb276