I just wanted to say thank you for the sharp advise you provided to me more
than a week ago when I was in need.
-----Original Message-----
From: Dain Anderson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 26, 2001 11:04 PM
To: CF-Community
Subject: Re: TRIM or REPLACE?
Timothy,
If you know for certain your field always has a "dash" (-) in the string,
you could do this with a one-liner:
<cfset string = GetToken(String, 2, "-")>
Dain Anderson
Caretaker, CF Comet
http://www.cfcomet.com/
----- Original Message -----
From: "Timothy Dineen" <[EMAIL PROTECTED]>
To: "CF-Community" <[EMAIL PROTECTED]>
Sent: Thursday, July 26, 2001 9:12 PM
Subject: TRIM or REPLACE?
> Hey everyone:
>
> OK, On a good day I could do this, but this hasn't been a good day:
>
> I need to take a variable and either TRIM it or REPLACE characters in it
so
> that I end up with the same variable I started with minus the first two
> characters.
>
> For example, I have a field in the database as "F-12345" and I need to
drop
> the "F-" portion. The "12345" portion and be a random length or could
> contain alphabetical characters, so I can't just RIGHT() the last five
> numbers...
>
> Combo of REPLACE and TRIM or is there a better method?
> Any help is appreciated.
>
> Thanks, Tim
> Exposure.com
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/cf-community@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists