User Profile

Collapse

Profile Sidebar

Collapse
dirknrw
dirknrw
Last Activity: Nov 7 '08, 02:22 PM
Joined: Nov 7 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Hi all,

    a fellow of mine found already the answer:

    "M1000C1" string can be found in many lines, therefore many sections are found...

    You need to use the bounderies notation (word bounderies):

    solution for 2) use \b<searchpatter >\b

    [kilian_koala]sharan:~/tmp/koala/nokkcc (193) % perl -ne 'print if /\bM1000C1\b/ .. /<\/Counter>/' nokrwwKOALA.xml
    ...
    See more | Go to post

    Leave a comment:


  • perl -e matching lines between two search patterns - not working

    Hi,

    I have a tricky question!? :-)

    I'm using the perl -e command in order to match lines between two search patterns. The problem I have is, for the first example it is working, for the second not, but I can't see the difference:

    1) ok:

    [kilian_koala]sharan:~/tmp/koala/nokkcc (171) % perl -ne 'print if /M1000C0/ .. /<\/Counter>/' nokrwwKOALA.xml

    <Counter ID="ave_prxtot_ class_0"...
    See more | Go to post
No activity results to display
Show More
Working...