By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,660 Members | 1,267 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,660 IT Pros & Developers. It's quick & easy.

Regex help

P: 1
Hi -

Please help me with the following. I have to a parse a log file and here is the part of the log file which occurs repetitively.

[Text1] [Text2] [Text3] [Text4] [Text5] [Text6] [Text7] [

===== PATTERN1 =======

Text8_line1: value1

Text8_line2: value2

Text8_line3: value3

Text8_line4: value4

.

.

.

Text8_linen: valuen

===== PATTERN1 =======

]

So basically I want to copy the text fields (i.e. Text1,Text2, ...... Text8) into different array or scalar variable for further processing. The brackets ([ and ]) for Text 8 are in different lines.

Please help me with this.

Thanks.

-Navsaug
Sep 10 '08 #1
Share this Question
Share on Google+
4 Replies


numberwhun
Expert Mod 2.5K+
P: 3,503
Well, what have you tried thus far to do this? Unfortunately, we are not a scripting service, but will instead happily help you with any issues with code you are working on.

Please post your code in code tags, explain what errors you are seeing and we will help you from there.

Regards,

Jeff
Sep 10 '08 #2

eWish
Expert 100+
P: 971
What are you using as a delimiter? You could use split. Also, do please post the code that you have tried.

--Kevin
Sep 10 '08 #3

KevinADC
Expert 2.5K+
P: 4,059
Hes just looking for someone to write the code judging by the number of forums he has this question posted on.
Sep 10 '08 #4

numberwhun
Expert Mod 2.5K+
P: 3,503
Hes just looking for someone to write the code judging by the number of forums he has this question posted on.
That's what I figured. He can either put up his code or pay someone to do it for him.
Sep 11 '08 #5

Post your reply

Sign in to post your reply or Sign up for a free account.