[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#17086: Reg : Bug in Grep command
From: |
Norihiro Tanaka |
Subject: |
bug#17086: Reg : Bug in Grep command |
Date: |
Wed, 26 Mar 2014 00:34:14 +0900 |
Hi Senthil,
(out of bugs, only list)
I don't seem that it's a grep's bug.
Is the thing which you want to do `grep -r "Mr\.*" f1.dat*' and
`grep -r "Mrs\.*" f1.dat*'? ^
^
Norihiro
On Mon, 24 Mar 2014 19:10:53 +0530
Senthil Kumar <address@hidden> wrote:
> Dear Person,
>
> I have found a bug in the below environment and using grep along with REGEX.
>
> *My aim*: To search a names having "Mr.*" and "Mrs.*" in f1.dat file
>
> $ cat /etc/*-release
> Enterprise Linux Enterprise Linux Server release 5.8 (Carthage)
> Oracle Linux Server release 5.8
> Red Hat Enterprise Linux Server release 5.8 (Tikanga)
>
> *$ cat f1.dat*
> *Output:*
> MRavi
> Mr.Kumar
> Mrs.Linda
> Mrs.Lily
> Mr.Gul
> Mr.Tent
> Mrs.Forrest
> Mr.Hammer
>
> *$ grep -r "Mr.*" f1.dat*
> *Output:*
> Mr.Kumar
> Mrs.Linda
> Mrs.Lily
> Mr.Gul
> Mr.Tent
> Mrs.Forrest
> Mr.Hammer
>
> *$ grep -r "Mrs.*" f1.dat*
> *Output:*
> Mrs.Linda
> Mrs.Lily
> Mrs.Forrest
>
> I see the command (*$ grep -r "Mr.*" f1.dat*) is getting retrieved all
> names having both
>
> *Mr. and Mrs.*
> please do let me know is this defect ? Hoping to get an revert mail on this.
>
> --
>
> * Thanks & Regards,KK Senthil Kumar*
--
田中 紀洋 (Norihiro TANAKA)
E-mail : address@hidden