<?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: how to grep a exactly string? in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966358#M119486</link>
    <description>Hi Stanely&lt;BR /&gt; &lt;BR /&gt;grep -w ABC&lt;BR /&gt;&lt;BR /&gt;Regards.&lt;BR /&gt;Ernesto.</description>
    <pubDate>Tue, 06 May 2003 07:56:57 GMT</pubDate>
    <dc:creator>Ernesto Cappello</dc:creator>
    <dc:date>2003-05-06T07:56:57Z</dc:date>
    <item>
      <title>how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966350#M119478</link>
      <description>hi~&lt;BR /&gt;&lt;BR /&gt;If I grep "ABC",&lt;BR /&gt;I will receive the result like follows:&lt;BR /&gt;&lt;BR /&gt;ABC&lt;BR /&gt;ABCD&lt;BR /&gt;ABCDEF&lt;BR /&gt;&lt;BR /&gt;If I only want the result "ABC" return, how does it do?</description>
      <pubDate>Tue, 06 May 2003 07:32:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966350#M119478</guid>
      <dc:creator>Stanley_8</dc:creator>
      <dc:date>2003-05-06T07:32:44Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966351#M119479</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;You can use : grep "ABC "&lt;BR /&gt;&lt;BR /&gt;Franky</description>
      <pubDate>Tue, 06 May 2003 07:34:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966351#M119479</guid>
      <dc:creator>Franky Leeuwerck_1</dc:creator>
      <dc:date>2003-05-06T07:34:41Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966352#M119480</link>
      <description>&lt;BR /&gt;grep "ABC$"&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 06 May 2003 07:38:02 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966352#M119480</guid>
      <dc:creator>Stefan Farrelly</dc:creator>
      <dc:date>2003-05-06T07:38:02Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966353#M119481</link>
      <description>No..&lt;BR /&gt;It's not working!&lt;BR /&gt;&lt;BR /&gt;ex:&lt;BR /&gt;#ps -ef|grep "ABC"&lt;BR /&gt;&lt;BR /&gt;It will return all the line contain "ABC".&lt;BR /&gt;I want it return include "ABC" exactly.&lt;BR /&gt;Not "ABCD" or "ABCDEFR".</description>
      <pubDate>Tue, 06 May 2003 07:39:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966353#M119481</guid>
      <dc:creator>Stanley_8</dc:creator>
      <dc:date>2003-05-06T07:39:32Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966354#M119482</link>
      <description>Hi~&lt;BR /&gt;&lt;BR /&gt;grep "ABC$" is not working too.&lt;BR /&gt;&lt;BR /&gt;I can't find anything.</description>
      <pubDate>Tue, 06 May 2003 07:42:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966354#M119482</guid>
      <dc:creator>Stanley_8</dc:creator>
      <dc:date>2003-05-06T07:42:49Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966355#M119483</link>
      <description>Hi Stanley,&lt;BR /&gt;quite tricky. On 11.11 and onwards you can use the grep -w ABC for an exact match. On older versions you have to define something that makes it distinctive from the other possibilities, e.g.:&lt;BR /&gt;# grep ABC infile1 | grep -v "[D-Z]&lt;BR /&gt;&lt;BR /&gt;but what can be used will depend on the situation. &lt;BR /&gt;&lt;BR /&gt;regards,&lt;BR /&gt;John K.&lt;BR /&gt;</description>
      <pubDate>Tue, 06 May 2003 07:47:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966355#M119483</guid>
      <dc:creator>john korterman</dc:creator>
      <dc:date>2003-05-06T07:47:35Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966356#M119484</link>
      <description>Hi Stanely&lt;BR /&gt; &lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 06 May 2003 07:56:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966356#M119484</guid>
      <dc:creator>Ernesto Cappello</dc:creator>
      <dc:date>2003-05-06T07:56:24Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966357#M119485</link>
      <description>Very trickey. Im not sure even grep -w will do it for you. You must define more the rules under which you want to find ABC - at the start of the line ? end of line ? with blanks either side of it ? etc.&lt;BR /&gt;&lt;BR /&gt;Try this;&lt;BR /&gt;&lt;BR /&gt;ps -ef|awk '{print $9}'|grep -x ABC&lt;BR /&gt;&lt;BR /&gt;But this will only work if the command part of ps has ABC only on it - nothing else, not /bin/ABC or ABCD etc.&lt;BR /&gt;</description>
      <pubDate>Tue, 06 May 2003 07:56:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966357#M119485</guid>
      <dc:creator>Stefan Farrelly</dc:creator>
      <dc:date>2003-05-06T07:56:56Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966358#M119486</link>
      <description>Hi Stanely&lt;BR /&gt; &lt;BR /&gt;grep -w ABC&lt;BR /&gt;&lt;BR /&gt;Regards.&lt;BR /&gt;Ernesto.</description>
      <pubDate>Tue, 06 May 2003 07:56:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966358#M119486</guid>
      <dc:creator>Ernesto Cappello</dc:creator>
      <dc:date>2003-05-06T07:56:57Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966359#M119487</link>
      <description>l1:/tmp 103 &amp;gt; cat xx&lt;BR /&gt;ABC&lt;BR /&gt;AABC&lt;BR /&gt;ABCC&lt;BR /&gt; ABC&lt;BR /&gt;CBA&lt;BR /&gt;ABCD&lt;BR /&gt;ABCDE&lt;BR /&gt;ABC DEF&lt;BR /&gt;FABC D&lt;BR /&gt;l1:/tmp 104 &amp;gt; perl -ne '/\bABC\b/ and print' xx&lt;BR /&gt;ABC&lt;BR /&gt; ABC&lt;BR /&gt;ABC DEF&lt;BR /&gt;l1:/tmp 105 &amp;gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Enjoy, have FUN! H.Merijn</description>
      <pubDate>Tue, 06 May 2003 08:12:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966359#M119487</guid>
      <dc:creator>H.Merijn Brand (procura</dc:creator>
      <dc:date>2003-05-06T08:12:18Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966360#M119488</link>
      <description>hi,&lt;BR /&gt;&lt;BR /&gt;grep -x ABC&lt;BR /&gt;&lt;BR /&gt;Regards</description>
      <pubDate>Tue, 06 May 2003 08:22:02 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966360#M119488</guid>
      <dc:creator>V. V. Ravi Kumar_1</dc:creator>
      <dc:date>2003-05-06T08:22:02Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966361#M119489</link>
      <description>hi Stanely,&lt;BR /&gt;  As Ravi said, grep -x will do the trick.&lt;BR /&gt;&lt;BR /&gt;from the man page&lt;BR /&gt;---&lt;BR /&gt;-x                  (eXact) Matches are recognized only when the&lt;BR /&gt;                               entire input line matches the fixed string or&lt;BR /&gt;                               regular expression.&lt;BR /&gt;---&lt;BR /&gt;&lt;BR /&gt;Is this what you are looking for&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;Umapathy&lt;BR /&gt;</description>
      <pubDate>Tue, 06 May 2003 08:26:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966361#M119489</guid>
      <dc:creator>Umapathy S</dc:creator>
      <dc:date>2003-05-06T08:26:39Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966362#M119490</link>
      <description>my OS version is 11.00.&lt;BR /&gt;no "-w" function included.&lt;BR /&gt;&lt;BR /&gt;I use "ps -ef" command and I want to grep the user name and the other information.&lt;BR /&gt;so I can't use the option "-x" to grep full line.&lt;BR /&gt;I try to use "awk" but only can find the user name . the other information was cut.</description>
      <pubDate>Tue, 06 May 2003 08:51:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966362#M119490</guid>
      <dc:creator>Stanley_8</dc:creator>
      <dc:date>2003-05-06T08:51:38Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966363#M119491</link>
      <description>Hi &lt;BR /&gt;I've this grep version &lt;BR /&gt;(grep -V)&lt;BR /&gt;            &lt;BR /&gt;grep (GNU grep) 2.2&lt;BR /&gt; (Cygnus)&lt;BR /&gt;Copyright (C) 1988, 92, 93, 94, 95, 96, 97 Free Software Foundation, Inc.&lt;BR /&gt;This is free software; see the source for copying conditions. There is NO&lt;BR /&gt;warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.&lt;BR /&gt;&lt;BR /&gt;and if i've 2 file "psgrep" and "psgreps"&lt;BR /&gt;&lt;BR /&gt;# &amp;gt;ll | grep -w psgrep&lt;BR /&gt;-rwx------ 1 X users 276 Dec 17 10:55 psgrep&lt;BR /&gt;&lt;BR /&gt;# &amp;gt;ll | grep psgrep   &lt;BR /&gt;-rwx------ 1 X users 276 Dec 17 10:55 psgrep&lt;BR /&gt;-rwx------ 1 X users 276 May  6 10:44 psgreps&lt;BR /&gt;&lt;BR /&gt;Regards.&lt;BR /&gt;Ernesto.&lt;BR /&gt;</description>
      <pubDate>Tue, 06 May 2003 09:11:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966363#M119491</guid>
      <dc:creator>Ernesto Cappello</dc:creator>
      <dc:date>2003-05-06T09:11:41Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966364#M119492</link>
      <description># ps -fu203&lt;BR /&gt;&lt;BR /&gt;gives you all the processes of user 203&lt;BR /&gt;&lt;BR /&gt;# ps -ef&lt;BR /&gt;&lt;BR /&gt;gives you *all* processes&lt;BR /&gt;&lt;BR /&gt;"And other information" is much to vague for us to solve&lt;BR /&gt;&lt;BR /&gt;Attached is a perl script that mimics ps behaviour (without using 'ps') and runs on HP-UX and AIX. Easy to modify to get other fields or info&lt;BR /&gt;&lt;BR /&gt;Enjoy, have FUN! H.Merijn</description>
      <pubDate>Tue, 06 May 2003 09:24:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966364#M119492</guid>
      <dc:creator>H.Merijn Brand (procura</dc:creator>
      <dc:date>2003-05-06T09:24:21Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966365#M119493</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Perhaps try it in another way ...&lt;BR /&gt;&lt;BR /&gt;ps -fu login&lt;BR /&gt;&lt;BR /&gt;Regards</description>
      <pubDate>Tue, 06 May 2003 09:24:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966365#M119493</guid>
      <dc:creator>Jean-Louis Phelix</dc:creator>
      <dc:date>2003-05-06T09:24:38Z</dc:date>
    </item>
    <item>
      <title>Re: how to grep a exactly string?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966366#M119494</link>
      <description>hi Stanley,&lt;BR /&gt;  The best alternate is to try ps -fu ABC instead of ps and grep.&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;Umapathy&lt;BR /&gt;</description>
      <pubDate>Tue, 06 May 2003 09:31:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-grep-a-exactly-string/m-p/2966366#M119494</guid>
      <dc:creator>Umapathy S</dc:creator>
      <dc:date>2003-05-06T09:31:46Z</dc:date>
    </item>
  </channel>
</rss>

