May 10, 2009 at 8:47 am
Does anyone know of a text editor to copy n lines after occurence of search pattern?
I have a huge file with over a thousand deadlock graphs.
I want to snag say the first threee lines after the occurence of the string "Wait for graph" . Is there a text editor out there that allows me do so?
May 10, 2009 at 12:56 pm
I'm no RegEx expert but it seems like something that most editor's RegEx search should be able to do.
[font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
Proactive Performance Solutions, Inc. [/font][font="Verdana"] "Performance is our middle name."[/font]
May 10, 2009 at 3:20 pm
raw text or RTF? editplus can do that easily to raw text,you just set a macro to search for a term to find the start, then make it select while searching for a end of line three times; you can make it rreleat the same action an unlimited number of timesw...it auto prompts you to continue every 10,000 repetitions of your macro.
Lowell
May 10, 2009 at 3:57 pm
Thanks for your reply
rbarryyoung - What I want to do is toi snag the first few lines of each deadlock graph to see if there's a common pattern among the 1000 or so deadlocks. Textpad etc. will allow me to sanp just the first line but not the subsequent ones
Lowell - I shall try out your rreccomendation for Editplus
I figured out that it would involve writing some sort of a macro - no matter what the text editor
May 10, 2009 at 4:07 pm
Rohit Nayak (5/10/2009)
Thanks for your replyrbarryyoung - What I want to do is toi snag the first few lines of each deadlock graph to see if there's a common pattern among the 1000 or so deadlocks. Textpad etc. will allow me to sanp just the first line but not the subsequent ones
Lowell - I shall try out your rreccomendation for Editplus
I figured out that it would involve writing some sort of a macro - no matter what the text editor
Their RegEx won't span lines? That's odd.
[font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
Proactive Performance Solutions, Inc. [/font][font="Verdana"] "Performance is our middle name."[/font]
May 11, 2009 at 10:38 am
UltraEdit
-MarkO
"You do not really understand something until you can explain it to your grandmother" - Albert Einstein
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply