Re: math with multiple [founditems]
This WebDNA talk-list message is from 1999
It keeps the original formatting.
numero = 23769
interpreted = N
texte = Ok that's the ticket! You should work for PCS tech support or something! :-PProblem solved.ThanksBrantPCS Technical Support wrote:> >I have a search that returns mulitple entries from one field (all> >numbers) and I'd like to add all those values together. I was thinking> >something like this:> >> >[founditems][math][fieldname]+[/math][/founditems]> >> >but of course this doesn't work. How could I make this work?>> You need the [math] context to be on the *outside* of the [FoundItems] loop.>> [math][founditems][fieldname]+[/founditems]0[/math]>> That trailing '0' is to make sure the equation finishes off with a number> instead of a dangling '+', so it would end up looking like this:>> [math]1+15+45+14+3+0[/math]>> Technical Support | ==== eCommerce and Beyond ====> Pacific Coast Software | WebCatalog, WebMerchant,> 11770 Bernardo Plaza Court | SiteEdit Pro, PhotoMaster,> San Diego, CA 92128 | Typhoon> 619/675-1106 Fax: 619/675-0372 | http://www.smithmicro.com/
Associated Messages, from the most recent to the oldest:
Ok that's the ticket! You should work for PCS tech support or something! :-PProblem solved.ThanksBrantPCS Technical Support wrote:> >I have a search that returns mulitple entries from one field (all> >numbers) and I'd like to add all those values together. I was thinking> >something like this:> >> >
[founditems][math][fieldname]+[/math][/founditems]> >> >but of course this doesn't work. How could I make this work?>> You need the
[math] context to be on the *outside* of the
[founditems] loop.>>
[math][founditems][fieldname]+[/founditems]0[/math]>> That trailing '0' is to make sure the equation finishes off with a number> instead of a dangling '+', so it would end up looking like this:>>
[math]1+15+45+14+3+0[/math]>> Technical Support | ==== eCommerce and Beyond ====> Pacific Coast Software | WebCatalog, WebMerchant,> 11770 Bernardo Plaza Court | SiteEdit Pro, PhotoMaster,> San Diego, CA 92128 | Typhoon> 619/675-1106 Fax: 619/675-0372 | http://www.smithmicro.com/
es-sleestak
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:
server2003 (2004)
Function defined inside Scope context (2005)
multiple prices (1998)
[random] only for 1-100??? (1997)
Nested vs conditional (1997)
Ruby on Rails (was Looping Search) (2006)
Quitting WebMerchant ? (1997)
Been meaning to ask... (1997)
2.0 Beta (1997)
[isfile] ? (1997)
Multihoming and webcat (1998)
Pithy questions on webcommerce & siteedit (1997)
Max Record length restated as maybe bug (1997)
quantity minimum problem (1997)
ampersand (1998)
WebDNA Solutions ... sorry! (1997)
Error Lob.db records error message not name (1997)
find with exceptions (1997)
Help getting [shownext] to increment (2003)
Download capabilities (1997)