Re: WebCat2 - [format thousands]
This WebDNA talk-list message is from 1997
It keeps the original formatting.
numero = 10579
interpreted = N
texte = >>What would you think of a new function that would remove all non-numeric>>characters ... except for one or more predefined characters which we as>>webmasters can set in the WebCatalog Prefs file? This would give us more>>control over numeric formatting, similar to the way we can preformat the>>date and time entries now.>>That sounds like a good idea. Perhaps not a function, but perhaps an>input form modifier that tell WebCatalog the incoming number should be a>number. Sounds like a good addition to 2.1Yes, I think this would be a very useful basic implementation of some newtext manipulation features.I was thinking more about this since I sent my original message. Panoramahas a very useful feature called 'change' which can change any part of astring which appears in a specified field - and it makes these changes tothe defined text string in every record of the database - instantly.In WebDNA, there might be two different applications for this type of[change] feature. One would be to manipulate all the values in a databasefield like Panorama does, for example:[changeData db=xxx&fieldName=description&find=a&changeTo=e] <-- this wouldwork like 'replace' in that it would act on every matching value in thedatabase ... but instead of replacing the entire value in a particularfield, it would only change 'part' of the data in that field.The other way to use this feature (or a similar feature) would be to make achange on a single value instead of changing every value in a databasefield. I think this is what you were referring to above when you said itshould be an input form modifier. For example:[changeText a=e]batter[/change] <-- would result in betteror ...[changeText er=]singer[/change] <-- would result in singor ...[changeText ,=]$1,234,567.89[/change] <-- would result in $1234567.89It would even be cooler to do a whole bunch of changes at once, like this:[changeText a=i&r=t&e=ti&b=s]barbell[/change] <-- would result in sitstillor ...[changeText ,=&$=&.=]$1,234,567.89[/change] <-- would result in 123456789The only character you couldn't change using this type of feature would bethe & sign. In a numbers-only field, a useful variation on 'change' wouldbe 'removeOtherText' which would remove all characters or strings (exceptfor the pre-defined characters or strings), for example:[removeOtherText 0 1 2 3 4 5 6 7 8 9 .]$345,221.79[/removeOtherText]<--would result in 345221.79Or you could pre-define this particularly useful text manipulation asfollows ...[removeOtherText float]$345,221.79[/removeOtherText] <--would result in345221.79Here are some more pre-defined 'text funnel' examples ...[removeOtherText alpha]Ken$1,239.17[/removeOtherText] <--would result in Ken[removeOtherText integer.]Ken$1,239.17[/removeOtherText] <--would resultin 1239In the example above, the dot after the integer parameter would tellWebCat2 what to 'look for' as the decimal separator. If there were nodecimal separator defined, then the result would be 123917 ... and if thedecimal separator were a comma instead of a dot, the results would be 1.In the case of this example using an 'integer' parameter, WebCat2 wouldidentify everything after the last 'decimal separator' in the string - andthe last decimal separator itself - as superfluous, so it would all bediscarded before the 'removeOtherText' function would be applied.I guess there could be any number of pre-defined text funnels defined ...but the basics could be covered reasonably well with just the basic two[changeText] and [removeOtherText] contexts.These two new tools alone would create a LOT of flexibility when inputtingdata. They would probably be most useful in number fields where searchingcan be problematic unless all the values have a consistent format. But I'msure other uses will be found for them as well. I can think of one on mysite right now ...but I don't think I should go into that on this list.I think I've said enough about these text manipulation possibilities fornow. If Grant or anyone else on the list thinks some of these things mightbe valuable additions to the WebDNA language, please, let's discuss them sowe can encourage WebCat2 to become everything we want and need it to be ...:)Sincerely,Ken------------------------------------To leave this talk list send an email to macjordomo@smithmicro.comwith BODYunsubscribe WebDNA-Talk------------------------------------
Associated Messages, from the most recent to the oldest:
>>What would you think of a new function that would remove all non-numeric>>characters ... except for one or more predefined characters which we as>>webmasters can set in the WebCatalog Prefs file? This would give us more>>control over numeric formatting, similar to the way we can preformat the>>date and time entries now.>>That sounds like a good idea. Perhaps not a function, but perhaps an>input form modifier that tell WebCatalog the incoming number should be a>number. Sounds like a good addition to 2.1Yes, I think this would be a very useful basic implementation of some newtext manipulation features.I was thinking more about this since I sent my original message. Panoramahas a very useful feature called 'change' which can change any part of astring which appears in a specified field - and it makes these changes tothe defined text string in every record of the database - instantly.In WebDNA, there might be two different applications for this type of[change] feature. One would be to manipulate all the values in a databasefield like Panorama does, for example:[changeData db=xxx&fieldName=description&find=a&changeTo=e] <-- this wouldwork like 'replace' in that it would act on every matching value in thedatabase ... but instead of replacing the entire value in a particularfield, it would only change 'part' of the data in that field.The other way to use this feature (or a similar feature) would be to make achange on a single value instead of changing every value in a databasefield. I think this is what you were referring to above when you said itshould be an input form modifier. For example:[changeText a=e]batter[/change] <-- would result in betteror ...[changeText er=]singer[/change] <-- would result in singor ...[changeText ,=]$1,234,567.89[/change] <-- would result in $1234567.89It would even be cooler to do a whole bunch of changes at once, like this:[changeText a=i&r=t&e=ti&b=s]barbell[/change] <-- would result in sitstillor ...[changeText ,=&$=&.=]$1,234,567.89[/change] <-- would result in 123456789The only character you couldn't change using this type of feature would bethe & sign. In a numbers-only field, a useful variation on 'change' wouldbe 'removeOtherText' which would remove all characters or strings (exceptfor the pre-defined characters or strings), for example:[removeOtherText 0 1 2 3 4 5 6 7 8 9 .]$345,221.79[/removeOtherText]<--would result in 345221.79Or you could pre-define this particularly useful text manipulation asfollows ...[removeOtherText float]$345,221.79[/removeOtherText] <--would result in345221.79Here are some more pre-defined 'text funnel' examples ...[removeOtherText alpha]Ken$1,239.17[/removeOtherText] <--would result in Ken[removeOtherText integer.]Ken$1,239.17[/removeOtherText] <--would resultin 1239In the example above, the dot after the integer parameter would tellWebCat2 what to 'look for' as the decimal separator. If there were nodecimal separator defined, then the result would be 123917 ... and if thedecimal separator were a comma instead of a dot, the results would be 1.In the case of this example using an 'integer' parameter, WebCat2 wouldidentify everything after the last 'decimal separator' in the string - andthe last decimal separator itself - as superfluous, so it would all bediscarded before the 'removeOtherText' function would be applied.I guess there could be any number of pre-defined text funnels defined ...but the basics could be covered reasonably well with just the basic two[changeText] and [removeOtherText] contexts.These two new tools alone would create a LOT of flexibility when inputtingdata. They would probably be most useful in number fields where searchingcan be problematic unless all the values have a consistent format. But I'msure other uses will be found for them as well. I can think of one on mysite right now ...but I don't think I should go into that on this list.I think I've said enough about these text manipulation possibilities fornow. If Grant or anyone else on the list thinks some of these things mightbe valuable additions to the WebDNA language, please, let's discuss them sowe can encourage WebCat2 to become everything we want and need it to be ...:)Sincerely,Ken------------------------------------To leave this
Talk List send an email to macjordomo@smithmicro.comwith BODYunsubscribe WebDNA-Talk------------------------------------
Kenneth Grome
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:
Why is [lookup] case sensitive? (2001)
[ConvertChars] problem (1997)
Bit off subject -- Faxing orders (1997)
emailer (1997)
6.0 upgrade issue? (2005)
[include ...] behavior (1997)
Here we go again...WebDNA - SQL- Clustering (2006)
Location of Browser Info.txt file (1997)
truncating email part II (1997)
Rhapsody? (1997)
date (1999)
OBDC Support (1997)
WebCat2: multiple currency support (1997)
[WebDNA] Free Hosting Amazon (2011)
Backwards list behavior ... (1997)
Problems mit mysql (2004)
Setting up WebCatalog with Retail Pro data (1996)
update on wn searching (1997)
[WebDNA] OLD list archives? (2010)
New (1998)