<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: grep command ?? in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892176#M103166</link>
    <description>if you're after an exact match try fgrep or the -F switch of grep (see manpage),&lt;BR /&gt;for more involved parsings use Perl (where amongst other things) you can set anchors in form of word boundaries.</description>
    <pubDate>Wed, 29 Jan 2003 16:25:04 GMT</pubDate>
    <dc:creator>Ralph Grothe</dc:creator>
    <dc:date>2003-01-29T16:25:04Z</dc:date>
    <item>
      <title>grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892175#M103165</link>
      <description>I am using grep command to look through a file for certain entries, like say the word test, but my problem is there are other entries in the file that begin with have test in them that I don't want returned.. &lt;BR /&gt;ie:&lt;BR /&gt;&lt;BR /&gt;test&lt;BR /&gt;test_107&lt;BR /&gt;tup_test&lt;BR /&gt;etc.....&lt;BR /&gt;&lt;BR /&gt;the grep for tet would return all three entries when I only want the 1st entry returned...&lt;BR /&gt;&lt;BR /&gt;any ways to get around this ??&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;Mike&lt;BR /&gt;</description>
      <pubDate>Wed, 29 Jan 2003 16:21:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892175#M103165</guid>
      <dc:creator>MikeL_4</dc:creator>
      <dc:date>2003-01-29T16:21:57Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892176#M103166</link>
      <description>if you're after an exact match try fgrep or the -F switch of grep (see manpage),&lt;BR /&gt;for more involved parsings use Perl (where amongst other things) you can set anchors in form of word boundaries.</description>
      <pubDate>Wed, 29 Jan 2003 16:25:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892176#M103166</guid>
      <dc:creator>Ralph Grothe</dc:creator>
      <dc:date>2003-01-29T16:25:04Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892177#M103167</link>
      <description>To return just lines that have the word 'test' (and only the word 'test'),...&lt;BR /&gt;&lt;BR /&gt;grep "^test$" &lt;BR /&gt;&lt;BR /&gt;^ = anchor to start of line&lt;BR /&gt;$ = anchor to end of line&lt;BR /&gt;&lt;BR /&gt;To get complete word test takes a little more effort.&lt;BR /&gt;&lt;BR /&gt;Share and Enjoy! Ian</description>
      <pubDate>Wed, 29 Jan 2003 16:26:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892177#M103167</guid>
      <dc:creator>Ian Dennison_1</dc:creator>
      <dc:date>2003-01-29T16:26:57Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892178#M103168</link>
      <description>Try-&lt;BR /&gt;&lt;BR /&gt;grep "^test$" file&lt;BR /&gt;&lt;BR /&gt;^ matches beginning of line&lt;BR /&gt;$ matches end of line&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;&lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Wed, 29 Jan 2003 16:27:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892178#M103168</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2003-01-29T16:27:11Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892179#M103169</link>
      <description>sorry -F alone wouldn't help I suppose,&lt;BR /&gt;append a [[:space:]] to you're regex while using egrep or -E switch (which stands for extended grep)&lt;BR /&gt;but that said, nothing compares to Perl's regex capabilities</description>
      <pubDate>Wed, 29 Jan 2003 16:28:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892179#M103169</guid>
      <dc:creator>Ralph Grothe</dc:creator>
      <dc:date>2003-01-29T16:28:44Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892180#M103170</link>
      <description>GNU grep knows -w option, which `anchors' the word to search for&lt;BR /&gt;&lt;BR /&gt;# grep -w test file&lt;BR /&gt;&lt;BR /&gt;GNU grep available on &lt;A href="http://www.cmve.net/~merijn" target="_blank"&gt;http://www.cmve.net/~merijn&lt;/A&gt; or &lt;A href="https://www.beepz.com/personal/merijn" target="_blank"&gt;https://www.beepz.com/personal/merijn&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Enjoy, have FUN! H.Merijn</description>
      <pubDate>Wed, 29 Jan 2003 16:29:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892180#M103170</guid>
      <dc:creator>H.Merijn Brand (procura</dc:creator>
      <dc:date>2003-01-29T16:29:00Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892181#M103171</link>
      <description>Hi Mike:&lt;BR /&gt;&lt;BR /&gt;Try this:&lt;BR /&gt;&lt;BR /&gt;grep test filename|head -n 1&lt;BR /&gt;&lt;BR /&gt;Tom&lt;BR /&gt;</description>
      <pubDate>Wed, 29 Jan 2003 16:29:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892181#M103171</guid>
      <dc:creator>Tom Jackson</dc:creator>
      <dc:date>2003-01-29T16:29:13Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892182#M103172</link>
      <description>Hi Mike:&lt;BR /&gt;&lt;BR /&gt;# grep -E -e " test " -e " test$" -e "^test " -e "^test$" &lt;BR /&gt;&lt;BR /&gt;...would limit the selection to the word "test".&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Wed, 29 Jan 2003 16:29:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892182#M103172</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2003-01-29T16:29:21Z</dc:date>
    </item>
    <item>
      <title>Re: grep command ??</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892183#M103173</link>
      <description>Mike,&lt;BR /&gt;&lt;BR /&gt;Try this:&lt;BR /&gt;&lt;BR /&gt;# grep -x test input_file&lt;BR /&gt;&lt;BR /&gt;Hai</description>
      <pubDate>Wed, 29 Jan 2003 16:30:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-command/m-p/2892183#M103173</guid>
      <dc:creator>Hai Nguyen_1</dc:creator>
      <dc:date>2003-01-29T16:30:34Z</dc:date>
    </item>
  </channel>
</rss>

