in reply to Help with regex

A couple of previous responses seemed to interpret your requirements as looking for anything that is not white space that appears after your 'Query=' but that is not how I read it. An alphanumeric character means that you only want alphabetical and/or numeric characters. A pipe '|' doesn't fit that rule.

perl -ne 'if(m/Query\=\s+(\S+)/){print $1};' monks1085293.data sp|P30443|1A01_HUMAN
Pipes...
perl -ne 'if(m/Query\=\s+([^\s]+)/){print $1};' monks1085293.data sp|P30443|1A01_HUMAN
Pipes...
perl -ne 'if(m/(?:Query\=|\>)\s?([A-Za-z0-9]+)/){print qq|$1\t|};' mon +ks1085293.data sp tr tr

Now this selects exactly what you are looking for...alphanumeric characters that follow either 'Query=' or '>'.

Celebrate Intellectual Diversity