Re: REGEX hell

2010-11-25 Thread denstar
On Thu, Nov 25, 2010 at 10:48 AM, Peter Boughton wrote: > > To be clear, CF uses the Apache ORO library, which is different to both Perl > and Java Regex. I've found the QuickREx Eclipse plugin *invaluable* for regular expression work. It supports several different regex engines, has "libraries

Re: REGEX hell

2010-11-25 Thread Peter Boughton
To be clear, CF uses the Apache ORO library, which is different to both Perl and Java Regex. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive

Re: REGEX hell

2010-11-25 Thread Peter Boughton
In this situation, there is no real difference between lazy or greedy - because the quantified item is mutually exclusive with the next characters - i.e. "\s+" cannot match "\)" - so it will always consume to the end of the whitespace. It is better to not assume lazy or greedy as a 'default' an

Re: REGEX hell

2010-11-25 Thread Charlie Griefer
... since we're throwing out recommendations for our favorite "so glad this exists because of how badly I suck at reg ex" apps, I've found http://gskinner.com/RegExr/desktop/ to be a -very- valuable tool. On Thu, Nov 25, 2010 at 8:56 AM, Dave Merrill wrote: > > Be a little careful, Regex Coach

Re: REGEX hell

2010-11-25 Thread Dave Merrill
Be a little careful, Regex Coach works with perl regex syntax; cf needs java syntax usually, with some differences. I can't recommend Regex Buddy highly enough. It's not free, but it's really quite excellent, supports a variety of different flavors. Dave On Thu, Nov 25, 2010 at 10:17 AM, Jerry

Re: REGEX hell

2010-11-25 Thread Jerry Barnes
Regex that is useful but unfortunately, my skills are pretty weak in that area. I use an application named "The Regex Coach' to build my code. It has a place to put the string you are trying to match and another place to put your regex code. As you modify the regex code, it highlights how much

Re: REGEX hell

2010-11-22 Thread Michael Dinowitz
atch as little as > possible. > > > > andy > > -Original Message- > From: Rick Colman [mailto:rcol...@cox.net] > Sent: Monday, November 22, 2010 9:59 PM > To: cf-talk > Subject: Re: REGEX hell > > > This worked!! TNX. > > On 11/22/2010 6:04

RE: REGEX hell

2010-11-22 Thread andy matthews
match as little as possible. andy -Original Message- From: Rick Colman [mailto:rcol...@cox.net] Sent: Monday, November 22, 2010 9:59 PM To: cf-talk Subject: Re: REGEX hell This worked!! TNX. On 11/22/2010 6:04 PM, Michael Dinowitz wrote: > Are you sure it's a space and not

Re: REGEX hell

2010-11-22 Thread Rick Colman
This worked!! TNX. On 11/22/2010 6:04 PM, Michael Dinowitz wrote: > Are you sure it's a space and not 2 spaces? Or a tab? Try using \s* to > indicate that there may be one or more space characters. > > \)\s*\) > > > > On Mon, Nov 22, 2010 at 8:48 PM, Rick Colman wrote: > >> I am trying to repla

Re: REGEX hell

2010-11-22 Thread Michael Dinowitz
Are you sure it's a space and not 2 spaces? Or a tab? Try using \s* to indicate that there may be one or more space characters. \)\s*\) On Mon, Nov 22, 2010 at 8:48 PM, Rick Colman wrote: > > I am trying to replace two trailing parens )) with a single paren. > > here is a sample string: > >

Re: REGEX hell

2010-11-22 Thread Jerry Johnson
no need to escape the space char with a slash. are you sure it is only 1 space, and are you sure it is a space char (chr(32))? If so, remove the slash in front of the space, and it should work. also, pet peeve, no need for the ## around the function. Works either way, though, so ignore if you p