- Aug
- 185
- 5
The documentation for the TPIPE /string filter shows the following type codes:
I'm finding the results I'm seeing a bit confusing, insofar as they seem the opposite of what this describes. Consider the following sample text:6 Remove lines matching the Perl pattern
7 Retain lines matching the Perl pattern
When I type this text through "tpipe /string=6,0,m/George/", I get:This is George's first line
This is Jimmy's first line
This is George's second line
This is Jimmy's second line
But when I type this text through "tpipe /string=7,0,m/George/" I get:This is George's first line
This is George's second line
From the docs, I expected type code 6 to remove the lines with 'George' and code 7 to retain them, but the output suggests the opposite. Is this because TPIPE "filters" things, so from the perspective of retaining in the filter they go away while I guess 'remove' ends up meaning they pass through the filter and are seen? Whatever the case, it seems to me like the documentation might be a little confusing. Thanks in advance!This is Jimmy's first line
This is Jimmy's second line