English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I am looking for a pattern / substitution that will accomplish the following results in PERL:

Original:

7:08:48 PM Msg Grp=ba.aig Thd=Thread-75 function one: Processed [5074] advisors.

7:08:48 PM Aud Grp=ss.ug Thd=Thread-55555 function two: Entered: 1182812928325

7:04:06 PM Dbg Grp=ss.sg Thd=Thread-2 CCSNameServiceAgent.getNarrowedObject(): Getting IOR information

Update:

7:08:48 PM function one: Processed [5074]

7:08:48 PM function two:

7:04:06 PM CCSNameServiceAgent.getNarrowedObject(): Getting IOR information


For the first match, the pattern will begin with "Msg", "Dbg" or "Aud"

If the first part is "Aud, Dbg or Msg" whatever in between and end with "-99" where 99 can be a number from one digit to many.

Thanks......

2007-06-25 13:30:13 · 3 answers · asked by Dante 2 in Computers & Internet Programming & Design

3 answers

Try this for starters and see how it works...

$s =~ s!(Aud|Dbg|Msg).+?Thread-\d+!!;

2007-06-26 13:52:52 · answer #1 · answered by martinthurn 6 · 0 0

If I get what you are asking this should be what you want...

$variable =~ s/(Msg|Dbg|Aud)(^\d+)(\d+)//;

I dont have perl on this comp to find out but I'll test it tomorrow and if its wrong you'll hear back from me.

2007-06-26 00:35:10 · answer #2 · answered by Bender 2 · 0 0

i'm so torn between 2 yet could bypass with the Rock vs HBK. which would be one in each and every of those good tournament! on condition that the two have by no potential fought one yet another until eventually now i could have enjoyed to make certain how they stacked up against one yet another. If no longer that tournament then truthfully the Bret vs HBK Revenge tournament, i could have payed huge greenbacks to make certain that stay. i'm a Shawn AND Bret fan yet lean extra to HBK yet nonetheless it may be large.

2016-10-03 03:22:23 · answer #3 · answered by ? 4 · 0 0

fedest.com, questions and answers