Re: [WebDNA] Advanced search 'rq' problem
This WebDNA talk-list message is from 2013
It keeps the original formatting.
numero = 110507
interpreted = N
texte = --Apple-Mail=_97BC1FA9-9214-4D5D-B4CA-37D4123D3183Content-Transfer-Encoding: quoted-printableContent-Type: text/plain;charset=windows-1252Yep=85=20Any RQ field is going to require match in order for it to be found in =results.I would just use a checkbox to allow them to require the field or not =and then use a simple hideif to include it into the search.search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D|13641=5894854176046|&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|&s=COMMITTEEdata=3D|136416335154313234|,|136416342654314722|&sSECTIONScomp=3D=wo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILdata[=showif [emailrequired]=3Dyes]rq[/showif]=3D[blank]FWIW, I have gotten into a habit of setting my entire search string as a =text variable above my searches.[text] =mysearchVAR=3DsSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D|136415=894854176046|&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|&sC=OMMITTEEdata=3D|136416335154313234|,|136416342654314722|&sSECTIONScomp=3Dw=o&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILdata[s=howif [emailrequired]=3D]rq[/showif]=3D[blank][/text]And then using the following for the search.search db=3Dpeople.db&[mysearchVAR]I do this for a few of reasons. First, for me, I find it far easier to =debug because I also do a lot of:[text]mysearch=3DsSECTIONSdata=3D|136407924352028766|[!][/!]&sBOFFICERdata=3D|136415894854176046|[!][/!]&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|[!][/!]&sCOMMITTEEdata=3D|136416335154313234|,|136416342654314722|[!][/!]&sSECTIONScomp=3Dwo[!][/!]&sBOFFICERcomp=3Dwo[!][/!]&sCOFFICERcomp=3Dwo[!][/!]&sCOMMITTEEcomp=3Dwo[!][/!]&nesEMAILdata[showif [emailrequired]=3D]rq[/showif]=3D[blank][!][/!][/text]Second, the string becomes easily usable on the page again (something I =find I use quite a bit) and if I have to later make changes to that =search logic then I don't have to worry about getting them all changed. =- Just the VARAnd lastly, For debugging I often include a formvariables and =listvariables at the bottom of my page wrapped in a showif based on =either a debug=3Dyes or cookie set on an admin login=85[showif [admincookie]=3Dyes][listvariables][name] =3D [value]
[listvariables][/showif]And this shows my my search strings on the browser making =troubleshooting a lot easier.Because I do everything in [SQL] and I am passing strings anyway it was =a natural progression and really worked well. Especially the debug mode =on the bottom where I can quickly spot my search issues. When your =search string is full of variables (and not hard coded data like your =example) this is a huge benefit because you can watch the variables =change and see if there is a problem in the dynamic search string.Anyway=85 I think the showif on the RQ is all you really need.HTHAlexOn Jul 15, 2013, at 12:47 PM, John Butler
=wrote:>> search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D|13641=5894854176046|&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|&s=COMMITTEEdata=3D|136416335154313234|,|136416342654314722|&sSECTIONScomp=3D=wo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILdatar=q=3D[blank]--Apple-Mail=_97BC1FA9-9214-4D5D-B4CA-37D4123D3183Content-Transfer-Encoding: quoted-printableContent-Type: text/html;charset=windows-1252Yep=85 Any RQ field is going to require match in order =for it to be found in results.
I would just use =a checkbox to allow them to require the field or not and then use a =simple hideif to include it into the =search.
search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D=|136415894854176046|&sCOFFICERdata=3D|136415955554188875|,|13641594765=4187207|&sCOMMITTEEdata=3D|136416335154313234|,|136416342654314722|&am=p;sSECTIONScomp=3Dwo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCO=MMITTEEcomp=3Dwo&nesEMAILdata[showif =[emailrequired]=3Dyes]rq[/showif]=3D[blank]
=
FWIW, I have gotten into a habit of setting my =entire search string as a text variable above my =searches.
[text] mysearchVAR=3DsSECTIONSdata==3D|136407924352028766|&sBOFFICERdata=3D|136415894854176046|&sCOFF=ICERdata=3D|136415955554188875|,|136415947654187207|&sCOMMITTEEdata=3D=|136416335154313234|,|136416342654314722|&sSECTIONScomp=3Dwo&sBOFF=ICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILd=ata[showif =[emailrequired]=3D]rq[/showif]=3D[blank][/text]
And then using the following for the =search.
search =db=3Dpeople.db&[mysearchVAR]
I= do this for a few of reasons. First, for me, I find it far easier to =debug because I also do a lot =of:
[text]mysearch=3DsSECTIONSdata=3D|136407=924352028766|[!]
[/!]&sBOFFICERdata=3D|136415894854176046|[!=]
[/!]&sCOFFICERdata=3D|136415955554188875|,|136415947654187=207|[!]
[/!]&sCOMMITTEEdata=3D|136416335154313234|,|13641634=2654314722|[!]
[/!]&sSECTIONScomp=3Dwo[!]
[/!]&=;sBOFFICERcomp=3Dwo[!]
[/!]&sCOFFICERcomp=3Dwo[!]
=[/!]&sCOMMITTEEcomp=3Dwo[!]
[/!]&nesEMAILdata[showif =[emailrequired]=3D]rq[/showif]=3D[blank][!]
[/!][/text]
Second, the string becomes easily usable on =the page again (something I find I use quite a bit) and if I have to =later make changes to that search logic then I don't have to worry about =getting them all changed. - Just the =VAR
And lastly, For debugging I =often include a formvariables and listvariables at the bottom of my page =wrapped in a showif based on either a debug=3Dyes or cookie set on an =admin login=85
[showif =[admincookie]=3Dyes]
[listvariables][name] =3D =[value]<br>[listvariables]
[/showif]
<=div>
And this shows my my search strings on the browser =making troubleshooting a lot easier.
Because I =do everything in [SQL] and I am passing strings anyway it was a natural =progression and really worked well. Especially the debug mode on the =bottom where I can quickly spot my search issues. When your search =string is full of variables (and not hard coded data like your example) =this is a huge benefit because you can watch the variables change and =see if there is a problem in the dynamic search =string.
Anyway=85 I think the =showif on the RQ is all you really =need.
HTH
Alex
search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D=|136415894854176046|&sCOFFICERdata=3D|136415955554188875|,|13641594765=4187207|&sCOMMITTEEdata=3D|136416335154313234|,|136416342654314722|&am=p;sSECTIONScomp=3Dwo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCO=MMITTEEcomp=3Dwo&nesEMAILdatarq=3D[blank]
=--Apple-Mail=_97BC1FA9-9214-4D5D-B4CA-37D4123D3183--
Associated Messages, from the most recent to the oldest:
--Apple-Mail=_97BC1FA9-9214-4D5D-B4CA-37D4123D3183Content-Transfer-Encoding: quoted-printableContent-Type: text/plain;charset=windows-1252Yep=85=20Any RQ field is going to require match in order for it to be found in =results.I would just use a checkbox to allow them to require the field or not =and then use a simple hideif to include it into the search.search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D|13641=5894854176046|&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|&s=COMMITTEEdata=3D|136416335154313234|,|136416342654314722|&sSECTIONScomp=3D=wo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILdata[=showif [emailrequired]=3Dyes]rq[/showif]=3D[blank]FWIW, I have gotten into a habit of setting my entire search string as a =text variable above my searches.[text] =mysearchVAR=3DsSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D|136415=894854176046|&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|&sC=OMMITTEEdata=3D|136416335154313234|,|136416342654314722|&sSECTIONScomp=3Dw=o&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILdata[s=howif [emailrequired]=3D]rq[/showif]=3D[blank][/text]And then using the following for the search.search db=3Dpeople.db&[mysearchVAR]I do this for a few of reasons. First, for me, I find it far easier to =debug because I also do a lot of:[text]mysearch=3DsSECTIONSdata=3D|136407924352028766|[!][/!]&sBOFFICERdata=3D|136415894854176046|[!][/!]&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|[!][/!]&sCOMMITTEEdata=3D|136416335154313234|,|136416342654314722|[!][/!]&sSECTIONScomp=3Dwo[!][/!]&sBOFFICERcomp=3Dwo[!][/!]&sCOFFICERcomp=3Dwo[!][/!]&sCOMMITTEEcomp=3Dwo[!][/!]&nesEMAILdata[showif [emailrequired]=3D]rq[/showif]=3D[blank][!][/!][/text]Second, the string becomes easily usable on the page again (something I =find I use quite a bit) and if I have to later make changes to that =search logic then I don't have to worry about getting them all changed. =- Just the VARAnd lastly, For debugging I often include a formvariables and =listvariables at the bottom of my page wrapped in a showif based on =either a debug=3Dyes or cookie set on an admin login=85[showif [admincookie]=3Dyes][listvariables][name] =3D [value]
[listvariables][/showif]And this shows my my search strings on the browser making =troubleshooting a lot easier.Because I do everything in [SQL] and I am passing strings anyway it was =a natural progression and really worked well. Especially the debug mode =on the bottom where I can quickly spot my search issues. When your =search string is full of variables (and not hard coded data like your =example) this is a huge benefit because you can watch the variables =change and see if there is a problem in the dynamic search string.Anyway=85 I think the showif on the RQ is all you really need.HTHAlexOn Jul 15, 2013, at 12:47 PM, John Butler =wrote:>> search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D|13641=5894854176046|&sCOFFICERdata=3D|136415955554188875|,|136415947654187207|&s=COMMITTEEdata=3D|136416335154313234|,|136416342654314722|&sSECTIONScomp=3D=wo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILdatar=q=3D[blank]--Apple-Mail=_97BC1FA9-9214-4D5D-B4CA-37D4123D3183Content-Transfer-Encoding: quoted-printableContent-Type: text/html;charset=windows-1252Yep=85 Any RQ field is going to require match in order =for it to be found in results.
I would just use =a checkbox to allow them to require the field or not and then use a =simple hideif to include it into the =search.
search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D=|136415894854176046|&sCOFFICERdata=3D|136415955554188875|,|13641594765=4187207|&sCOMMITTEEdata=3D|136416335154313234|,|136416342654314722|&am=p;sSECTIONScomp=3Dwo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCO=MMITTEEcomp=3Dwo&nesEMAILdata[showif =[emailrequired]=3Dyes]rq[/showif]=3D[blank]
=
FWIW, I have gotten into a habit of setting my =entire search string as a text variable above my =searches.
[text] mysearchVAR=3DsSECTIONSdata==3D|136407924352028766|&sBOFFICERdata=3D|136415894854176046|&sCOFF=ICERdata=3D|136415955554188875|,|136415947654187207|&sCOMMITTEEdata=3D=|136416335154313234|,|136416342654314722|&sSECTIONScomp=3Dwo&sBOFF=ICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCOMMITTEEcomp=3Dwo&nesEMAILd=ata
[showif =[emailrequired]=3D]rq[/showif]=3D[blank][/text]
And then using the following for the =search.
search =db=3Dpeople.db&[mysearchVAR]
I= do this for a few of reasons. First, for me, I find it far easier to =debug because I also do a lot =of:
[text]mysearch=3DsSECTIONSdata=3D|136407=924352028766|
[!] [/!]&sBOFFICERdata=3D|136415894854176046|[!=]
[/!]&sCOFFICERdata=3D|136415955554188875|,|136415947654187=207|
[!][/!]&sCOMMITTEEdata=3D|136416335154313234|,|13641634=2654314722|
[!][/!]&sSECTIONScomp=3Dwo
[!][/!]&=;sBOFFICERcomp=3Dwo
[!][/!]&sCOFFICERcomp=3Dwo
[!]=[/!]&sCOMMITTEEcomp=3Dwo
[!][/!]&nesEMAILdata
[showif =[emailrequired]=3D]rq[/showif]=3D[blank]
[!][/!][/text]
Second, the string becomes easily usable on =the page again (something I find I use quite a bit) and if I have to =later make changes to that search logic then I don't have to worry about =getting them all changed. - Just the =VAR
And lastly, For debugging I =often include a formvariables and listvariables at the bottom of my page =wrapped in a showif based on either a debug=3Dyes or cookie set on an =admin login=85
[showif =[admincookie]=3Dyes]
[/showif]
<=div>
And this shows my my search strings on the browser =making troubleshooting a lot easier.
Because I =do everything in
[SQL] and I am passing strings anyway it was a natural =progression and really worked well. Especially the debug mode on the =bottom where I can quickly spot my search issues. When your search =string is full of variables (and not hard coded data like your example) =this is a huge benefit because you can watch the variables change and =see if there is a problem in the dynamic search =string.
Anyway=85 I think the =showif on the RQ is all you really =need.
HTH
Alex
search =db=3Dpeople.db&sSECTIONSdata=3D|136407924352028766|&sBOFFICERdata=3D=|136415894854176046|&sCOFFICERdata=3D|136415955554188875|,|13641594765=4187207|&sCOMMITTEEdata=3D|136416335154313234|,|136416342654314722|&am=p;sSECTIONScomp=3Dwo&sBOFFICERcomp=3Dwo&sCOFFICERcomp=3Dwo&sCO=MMITTEEcomp=3Dwo&nesEMAILdatarq=3D[blank]
=--Apple-Mail=_97BC1FA9-9214-4D5D-B4CA-37D4123D3183--
Alex McCombie
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:
$purchase WITHOUT creditcar (1997)
Was cart limit-- Limits (2002)
[ot] g5 xserve drives (2004)
Mac to Windows (2000)
Buying sans cart (1997)
newbie question about zip code search (2003)
Looking for a Manual (1997)
Multiple transactions per cart (2000)
a search based on ^(contains) (1998)
Linked lists and Recursive searching (2003)
This message couldn't reach the list! (multi-column (1998)
[WebDNA] Serial numbers and pricing for WebDNA 7.0 (2011)
WebCatalog 2.0.1 NT beta 1 released (1997)
Writefile outside WebSTAR hierarchy? (1997)
bugs w/! &/or bad scripting??? (1997)
Emailer (1997)
Re2: frames & carts (1997)
Quickie question on the email templates (1997)
financial calculation (2000)
E-mailer error codes (1997)