Date: Wed, 1 Nov 2000 16:31:27 EST
Reply-To: Bernard Tremblay <imaginasys@HOTMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Bernard Tremblay <imaginasys@HOTMAIL.COM>
Subject: Re: remove extra space in character string
Content-Type: text/plain; charset=iso-8859-1; format=flowed
Hi Karsteen & Xu,
Just try the function COMPBL it removes extra spaces in a text.
As simple as that!
Regards,
\\\|///
\\ - - //
( @ @ )
+-----oOOo-(_)-oOOo--+-----------------------------------+
| Bernard Tremblay | |
| CSST | Tel: (418) 528-9313 |
| | Fax: (418) 528-1493 |
| | Int: Bernard.Tremblay@csst.qc.ca |
+----------------------------+---------------------------+
| Imaginasys enr | Res: (418) 658-1411 |
| | Int: bertrem@videotron.ca |
| | Hot: imaginasys@hotmail.com |
+--------------Oooo--+-----------------------------------+
oooO ( )
( ) ) /
\ ( (_/
\_)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>From: kmself@IX.NETCOM.COM
>Reply-To: kmself@IX.NETCOM.COM
>To: SAS-L@LISTSERV.UGA.EDU
>Subject: Re: remove extra space in character string
>Date: Wed, 1 Nov 2000 12:33:02 -0800
>
>on Wed, Nov 01, 2000 at 10:54:19AM -0800, Xu, Meifen (mxu@AMGEN.COM) wrote:
> > Hello, there:
> >
> > I have a character variable with most character string looking very
>regular.
> > But there are a few strings among the words having more than one space.
>I
> > certainly want to eliminate these extra space and tried translate(var, '
>',
> > ' '). It turned to me it does not work out. I don't think compress can
> > function at this case because between words one space needed for sure.
> >
> > Here is the string that I want to deal with:
> >
> > My leg was injured. this is original one.
> >
> > I like it looking like:
> >
> > My leg was injured.
>
> s/ *// /g
>
>...Damn! Wrong list!! <g>
>
>...the mad evangelist strikes again...
>
>--
>Karsten M. Self <kmself@ix.netcom.com> http://www.netcom.com/~kmself
> Evangelist, Opensales, Inc. http://www.opensales.org
> What part of "Gestalt" don't you understand? There is no K5 cabal
> http://gestalt-system.sourceforge.net/ http://www.kuro5hin.org
><< attach3 >>
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
Share information about yourself, create your own public profile at
http://profiles.msn.com.
|