Getting back to the basic issue of what are the blanks in a data set, I
still like the feature of being able to switch the display to Hex On and
also to be able to search for non-printing characters so that I could
identify them and choose how to deal with them. These features were
available in ISPF on the mainframe and as I recall are available in a couple
of the PC editors that I have not tried.
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of toby
Sent: Tuesday, February 08, 2011 12:26 PM
Subject: Re: Strip Function And Leading and Trailing Tab Chars
It takes less time and effort for the RegEx engine to run the two calls
seperately than it would
if it were all in one big honker RegEx call. In short having to match
in the middle of the string eats up way too much time and negates the
optimizers ability to optimize.
By breaking it down the optimizer can see that it only needs to match the
whitespace from the start
of the string to the first non-whitespace character. It then stops the
match and moves on to the
replacement part of the search and replace operation.
"I'm a hell bent 100% Texan til I die"
"Don't touch my Willie, I don't know you that well"
> Date: Tue, 8 Feb 2011 11:46:56 -0500
> From: tom.abernathy@GMAIL.COM
> Subject: Re: Strip Function And Leading and Trailing Tab Chars
> To: SAS-L@LISTSERV.UGA.EDU
> On Tue, 8 Feb 2011 16:39:14 +0000, toby dunn <tobydunn@HOTMAIL.COM> wrote:
> >PrxChange( 's/\s*$//o' , 1 , Text )
> >PrxChange( 's/^\s*//o' , 1 , Text )
> Toby -
> Why does it need two statements? Is there no way to select out the middle
> (non-white space) part in one regx? Is it because the matches are too
> - Tom