Pattern match excluding spaces???

Get help with installation and running here.

Moderators: DataMystic Support, Moderators

Posts: 13
Joined: Sat Nov 10, 2007 11:10 am

Pattern match excluding spaces???

Postby ezinestein » Sun May 22, 2011 10:00 am

Hello again,

As always, thank you for your help! I will usually spend a couple hours trying to figure something out, but then as a last resort I come here for help. I hope that's ok.

Is there a way to pattern match a line that has spaces... when the words I have do not have spaces?

Here is what I mean...

If I have a phrase like... 'california traffic school' in a text file... and I'd like to extract it... but all I have in another text file is that phrase minus the spaces... like... 'californiatrafficschool'...

Is there a way for me to extract the phrase with spaces using the matching phrase I have is without the spaces?

So again, I have this... 'dogtrainingvideos' and I'd like to extract the same phrase from a file... but the phrase has spaces between words like... 'dog training videos'.

Thank you.


User avatar
DataMystic Support
Site Admin
Posts: 2139
Joined: Mon Jun 30, 2003 12:32 pm
Location: Melbourne, Australia

Re: Pattern match excluding spaces???

Postby DataMystic Support » Mon May 23, 2011 11:25 am

Hi Ed,

Not, you can't do this. You would have to pre-process the file with 'california traffic school' in it so that it becomes
'californiatrafficschool', perhaps add line numbers, and then run the matching filter against it for californiatrafficschool.

Another approach would be to generate a file with 2 fields - e.g.

"california traffic school","californiatrafficschool"
"dog training videos'","dogtrainingvideos"

Then you can replace each match with, say, ##FOUND##, and then extract just those lines.

Simon Carter, - Insulin dose calculator for Type 1 diabetes - 250,000 free software downloads - send huge email attachments

Return to “TextPipe Tips and Tricks, Questions and Support”

Who is online

Users browsing this forum: Bing [Bot], Yahoo [Bot] and 11 guests