Re: Mixing and/or in searches

This WebDNA talk-list message is from

1998


It keeps the original formatting.
numero = 17072
interpreted = N
texte = >>I'm trying to perform a search that returns items that are marked as >>featured or have been added to our stock in the last three weeks. In >>addition, I want all the found items to cost more than $10, and have >>inventory greater than 5. >> >>I currently have: >>[SEARCH >>db=My.db&grINVdatarq=5&grPRICEdatarq=10&pricetype=num&invtype=num&eqFEATdata=1 >>&g >>rCDATEdata=[MATH DATE]{[DATE]}-21[/MATH]&CDATEtype=date] > > >Try this: > >[SEARCH db=My.db&eqFEATdata=1&CDATEtype=date&grCDATEdata=[MATH >DATE]{[DATE]}-21[/MATH]] > [founditems] > [showif [price]>10] > [showif [inv]>5] > --this is where the proper founditems will be displayed-- > [/showif] > [/showif] > [/founditems] >[/search]I don't think this is necessary. I think Michael's original search would be right if he just adds &AllReqd=T at the end (and skips the rq in the rest of the context if he wants a cleaner code). ************************************************************* Christer Olsson Stora Nygatan 21 Phone +46 40 791 50 Art director S-211 37 Malmoe Fax +46 40 97 99 77 Ljusa Ideer AB Sweden http://www.ljusaideer.se Associated Messages, from the most recent to the oldest:

    
  1. Re: Mixing and/or in searches (Michael Winston 1998)
  2. Re: Mixing and/or in searches (Christer Olsson 1998)
  3. Re: Mixing and/or in searches (Kenneth Grome 1998)
  4. Mixing and/or in searches (Michael Winston 1998)
>>I'm trying to perform a search that returns items that are marked as >>featured or have been added to our stock in the last three weeks. In >>addition, I want all the found items to cost more than $10, and have >>inventory greater than 5. >> >>I currently have: >>[SEARCH >>db=My.db&grINVdatarq=5&grPRICEdatarq=10&pricetype=num&invtype=num&eqFEATdata=1 >>&g >>rCDATEdata=[MATH DATE]{[date]}-21[/MATH]&CDATEtype=date] > > >Try this: > >[SEARCH db=My.db&eqFEATdata=1&CDATEtype=date&grCDATEdata=[MATH >DATE]{[date]}-21[/MATH]] > [founditems] > [showif [price]>10] > [showif [inv]>5] > --this is where the proper founditems will be displayed-- > [/showif] > [/showif] > [/founditems] >[/search]I don't think this is necessary. I think Michael's original search would be right if he just adds &AllReqd=T at the end (and skips the rq in the rest of the context if he wants a cleaner code). ************************************************************* Christer Olsson Stora Nygatan 21 Phone +46 40 791 50 Art director S-211 37 Malmoe Fax +46 40 97 99 77 Ljusa Ideer AB Sweden http://www.ljusaideer.se Christer Olsson

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:

Closing Databases (1998) getchars broken? (1997) [showif]/[hideif] question (1997) Another IfThenElse question.. (2003) WebCat2.0 [format thousands .0f] no go (1997) Security Issues and WebCommerce Solution (1997) sendmail spaces (1997) Error 11 (1996) [WebDNA] "Technical Reference" link broken in admin (2013) Can't add a field (1998) synching databases on multiple servers (1997) Adding up line items. (2000) more info on [setlineitems] (1997) Part Html part WebDNA (1997) where to put code (1998) Banner DNA (1997) Client-side Image Maps and WebCat? (1998) Emailer Set Up (1997) Math (1997) more on my bbs (1997)