Re: String manipulation in Webcatalog
This WebDNA talk-list message is from 2001
It keeps the original formatting.
numero = 39065
interpreted = N
texte = [grepsearch=0+([0-9]+)0+&replace=\1][likenumber][/grep]this just gets rid of the initial zeros......0010200 results in 10200 --- John Peacock
wrote: > LaegEnt. wrote:> > > > I have a number like 000004567000000> > > > I am unsure how many zeros are before the actual> > number and unsure how many after. I need to> extract> > the number. How do you do this in Webcatalog? Its> > seems pretty weak on string manipulation.> > > > [math][likenumber]+0[/math] will get you 4567000000> (since 0's after> the number are usually relevant).> > or [grep> search=0+([0-9]+)0+&replace=\1][likenumber][/grep]> > will strip all trailing and preceeding zeros, but> preserve embedded> zeros.> > John> > -- > John Peacock> Director of Information Research and Technology> Rowman & Littlefield Publishing Group> 4720 Boston Way> Lanham, MD 20706> 301-459-3366 x.5010> fax 301-429-5747> >-------------------------------------------------------------> This message is sent to you because you are> subscribed to> the mailing list> .> To unsubscribe, E-mail to:> > To switch to the DIGEST mode, E-mail to> > Web Archive of this list is at:http://search.smithmicro.com/ ____________________________________________________________Do You Yahoo!?Get your free @yahoo.co.uk address at http://mail.yahoo.co.ukor your free @yahoo.ie address at http://mail.yahoo.ie-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/
Associated Messages, from the most recent to the oldest:
[grepsearch=0+([0-9]+)0+&replace=\1][likenumber][/grep]this just gets rid of the initial zeros......0010200 results in 10200 --- John Peacock wrote: > LaegEnt. wrote:> > > > I have a number like 000004567000000> > > > I am unsure how many zeros are before the actual> > number and unsure how many after. I need to> extract> > the number. How do you do this in Webcatalog? Its> > seems pretty weak on string manipulation.> > > > [math][likenumber]+0[/math] will get you 4567000000> (since 0's after> the number are usually relevant).> > or [grep> search=0+([0-9]+)0+&replace=\1][likenumber][/grep]> > will strip all trailing and preceeding zeros, but> preserve embedded> zeros.> > John> > -- > John Peacock> Director of Information Research and Technology> Rowman & Littlefield Publishing Group> 4720 Boston Way> Lanham, MD 20706> 301-459-3366 x.5010> fax 301-429-5747> >-------------------------------------------------------------> This message is sent to you because you are> subscribed to> the mailing list> .> To unsubscribe, E-mail to:> > To switch to the DIGEST mode, E-mail to> > Web Archive of this list is at:http://search.smithmicro.com/ ____________________________________________________________Do You Yahoo!?Get your free @yahoo.co.uk address at http://mail.yahoo.co.ukor your free @yahoo.ie address at http://mail.yahoo.ie-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/
Laeg Ent.
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
Converting a Magazine to a Web Site with WebCat (1999)
NT or Mac (1998)
Last digit of Credit Card Stripped (1997)
OT: JavaScript question (2001)
What am I missing (1997)
WebSTAR/WebCat is serving .db files! (1999)
Smart caching problems with 2.1b3? (1997)
Database Updates (1997)
Replacing a Word (1999)
FTP FOLDER PERMISSIONS (2004)
RE: E-mailer error codes (1997)
Interpret twice? (1997)
Form Weirdness (2002)
Date Formats (1997)
Record Modified Date - SQL ? (2000)
WebMerchant 1.6 and SHTML (1997)
syntax question, not in online refernce (1997)
Lost Records in Database (2001)
Text data with spaces in them... (1997)
I'm new be kind (1997)