Re: Alpha Sort - ignore certain characters
This WebDNA talk-list message is from 2003
It keeps the original formatting.
numero = 52698
interpreted = N
texte = James Ziegler wrote:> Greetings!> > I want to do a nice simple sort of a bunch of song titles. No problem,> except that certain songs begin with an apostrophe or a quotation mark or> some other non-alpha character, i.e.:> > 'Round About Autumn> > So is there a way to make this product come up with the other "R" products> where it belongs, instead of at the beginning of the list? Any way to tell> the sort to ignore certain characters?> > Thanks.I suppose a good way to do this is originally have a "sorting" field. This field would take the title (when entered into the .db) and stripany wierd character/s from the start (and do any other mod needed) before populating that field. If this is not an option then, After adding the "sortfield" field into the .db, you could write a utility... somethinglike:[search db=db.db&neTITLE_datarq=find_all][founditems][if ("[title]" ~ "'") | ("[title]" ~ "
")][then][replacefounditems]sortfield=[url][newtitle][/url][/replacefounditems][/then][/if][/founditems][/search]Add as many comparisons as you would like to the if statement.Run the utility, Then you have a"sortfield" to where you can sort from.Cheers,Donovan> > -- =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o DONOVAN D. BROOKE Eucalyptus Design Developer / Consultant <-Web Development (specializing in eCommerce), -> <-Graphic Design, and Pre-Press Consultation -> ADDRESS:> Donovan Brooke DBA Eucalyptus Design P.O. Box 260153 Madison, WI 53726-0153 PH:> 1.608.592.3567 email:> dbrooke@euca.us Web:> http://www.euca.us =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o-------------------------------------------------------------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://webdna.smithmicro.com/
Associated Messages, from the most recent to the oldest:
James Ziegler wrote:> Greetings!> > I want to do a nice simple sort of a bunch of song titles. No problem,> except that certain songs begin with an apostrophe or a quotation mark or> some other non-alpha character, i.e.:> > 'Round About Autumn> > So is there a way to make this product come up with the other "R" products> where it belongs, instead of at the beginning of the list? Any way to tell> the sort to ignore certain characters?> > Thanks.I suppose a good way to do this is originally have a "sorting" field. This field would take the title (when entered into the .db) and stripany wierd character/s from the start (and do any other mod needed) before populating that field. If this is not an option then, After adding the "sortfield" field into the .db, you could write a utility... somethinglike:[search db=db.db&neTITLE_datarq=find_all][founditems][if ("[title]" ~ "'") | ("[title]" ~ "")][then][replacefounditems]sortfield=[url][newtitle][/url][/replacefounditems][/then][/if][/founditems][/search]Add as many comparisons as you would like to the if statement.Run the utility, Then you have a"sortfield" to where you can sort from.Cheers,Donovan> > -- =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o DONOVAN D. BROOKE Eucalyptus Design Developer / Consultant <-Web Development (specializing in eCommerce), -> <-Graphic Design, and Pre-Press Consultation -> ADDRESS:> Donovan Brooke DBA Eucalyptus Design P.O. Box 260153 Madison, WI 53726-0153 PH:> 1.608.592.3567 email:> dbrooke@euca.us Web:> http://www.euca.us =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o-------------------------------------------------------------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://webdna.smithmicro.com/
Donovan
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:
Seeking Better Display of results... (1997)
RE: Answer: WebDelivery downloads alias, not original ? (1997)
Problem (1997)
Document Contains No Data! (1997)
all records returned. (1997)
Images (2000)
Trouble with Netscape (1998)
Emailer (1997)
Problems with Summary and WEBCAT (1999)
WebCat2final1 crashes (1997)
WebCatalog for Postcards ? (1997)
WCS Newbie question (1997)
Sales Tax db (1998)
major search problem (1998)
Robert Minor duplicate mail (1997)
Using a database with a short url (2000)
[WebDNA] INCLUDE file= in the footer (2009)
PCS Frames (1997)
Error: unknown exception (2000)
How to Display text in empty fields (1997)