Re: random sorting broken (was Re: Re[2]: php vs WebCatalog)

This WebDNA talk-list message is from

2000


It keeps the original formatting.
numero = 27161
interpreted = N
texte = John Hill,thanks for responding!I changed my search to- [Search db=Greetings.db&negreetingdata=nada&greetingsort=1&greetingsdir=ra&max=1&allhit=1] as per your recommendationand I still get the same 2 records, but now with a very rare third, but the other 9 (of 12) never get displayed. So it seems that the allhit=1 didn't help. But I will try hitting it 1,000 times and display a hit list like you did to see better.-John ButlerJohn Hill wrote:> >[Search db=Greetings.db&negreetingdata=nada&greetingsort=1&greetingsdir=ra&max=1] > > [FoundItems][interpret][greeting][/interpret][/FoundItems][/Search] > > > >where the Greeting.db has only one field (named greeting) with records like- > >hello [username]...Ž > >(no record's field is equal to nada) > > > >But I find that I can force reload the page repeatedly (like 100 times over 5 different > >days) and only get one of > >2 greetings returned out of 12 possible. I NEVER get the other records returned - EVER! > >(not in weeks of testing.) > >That seems much more broken than simply not very random to me. You guys think my code > >is done correctly? How can I improve it while still using the random function? > > I put together a quick test page and database identical to yours. The only difference is that I added the ALLHIT=1 parameter to the search. Although this isn't really necessary in this instance, in general, you should add it to searches like this. Remember, sorting only happens among results with the SAME hitcount (the hitcount is what is use to determine the automatic best result ranking for a given search). > > You can hit the test page and see the results for yourself at: > > http://search.smithmicro.com/random.tpl > > Note that the page does 1000 searches so it may take a few seconds to come up. > > John. > ------------------------------------------------------------- Brought to you by CommuniGate Pro - The Buzz Word Compliant Messaging Server. To end your Mail problems go to .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 Associated Messages, from the most recent to the oldest:

    
John Hill,thanks for responding!I changed my search to- [Search db=Greetings.db&negreetingdata=nada&greetingsort=1&greetingsdir=ra&max=1&allhit=1] as per your recommendationand I still get the same 2 records, but now with a very rare third, but the other 9 (of 12) never get displayed. So it seems that the allhit=1 didn't help. But I will try hitting it 1,000 times and display a hit list like you did to see better.-John ButlerJohn Hill wrote:> >[Search db=Greetings.db&negreetingdata=nada&greetingsort=1&greetingsdir=ra&max=1] > > [founditems][interpret][greeting][/interpret][/FoundItems][/Search] > > > >where the Greeting.db has only one field (named greeting) with records like- > >hello [username]...Ž > >(no record's field is equal to nada) > > > >But I find that I can force reload the page repeatedly (like 100 times over 5 different > >days) and only get one of > >2 greetings returned out of 12 possible. I NEVER get the other records returned - EVER! > >(not in weeks of testing.) > >That seems much more broken than simply not very random to me. You guys think my code > >is done correctly? How can I improve it while still using the random function? > > I put together a quick test page and database identical to yours. The only difference is that I added the ALLHIT=1 parameter to the search. Although this isn't really necessary in this instance, in general, you should add it to searches like this. Remember, sorting only happens among results with the SAME hitcount (the hitcount is what is use to determine the automatic best result ranking for a given search). > > You can hit the test page and see the results for yourself at: > > http://search.smithmicro.com/random.tpl > > Note that the page does 1000 searches so it may take a few seconds to come up. > > John. > ------------------------------------------------------------- Brought to you by CommuniGate Pro - The Buzz Word Compliant Messaging Server. To end your Mail problems go to .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 John Butler

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:

emailer (1997) Pass a form (2003) Re:quit command on NT (1997) WebCatalog for Postcards ? (1997) Problems with [Search] param - Mac Plugin b15 (1997) [WebDNA] two ideas for running a cluster of WebDNA servers (2019) WebCat2 - Getting to the browser's username/password data (1997) TRAINING videos - Prove IT. (1998) Now you see it now you donīt (1997) [format xs] freeze (1997) In Digest Dijon (2000) WebDNA 6 and OS X Tiger (2005) WC1.6 to WC2 date formatting (1997) Running 2 two WebCatalog.acgi's (1996) Version 4? (2000) Feature Request -COPYRECORD (2005) Showing specific [cart] contents (1998) Pasting from M$ Word (2001) showif comparison begins w/ and contains (1997) WebCat2 beta 11 - new prefs ... (1997)