Webmastersite.net
Register Log In

Advanced Search -

Comments on Advanced Search -

siteengineering
Member

Usergroup: Customer
Joined: Feb 16, 2005

Total Topics: 4
Total Comments: 21
Posted Mar 11, 2005 - 3:12 AM:

Site under development but WSN (v3.14) functionality is largely in place:
http://www.ulster.com/directory/search.php

D/b contains 12 test records.

Searching "company or organisation name" field for "has ANY of the words" "site company fishmarket" (without quotes) should return 4 records (I think). In fact it returns all 12.

Searching "company or organisation name" field for "has ALL of the words" "company clothing" (without quotes) should return only 1 record. In fact it returns all 12.

All records are returned under the above conditions even if another search field is also specified in advanced search. The problem is not particular to the "company or organisation name" field - it occurs for all fields using any/all.

I won't make any changes to the test records until this is resolved, so that you can see exactly the same issues.

Thanks!
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Mar 11, 2005 - 8:47 PM:

Tell me if the title field is selected as a searchable field for links. I rememeber a WSN Forum bug where too many results were showing in an advanced search when a field wasn't marked as simple-searchable.
siteengineering
Member

Usergroup: Customer
Joined: Feb 16, 2005

Total Topics: 4
Total Comments: 21
Posted Mar 12, 2005 - 7:09 AM:

Thanks for reply. All five of the link fields in that form are set as searchable in the Functionality section of the admin panel.

Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Mar 13, 2005 - 9:09 PM:

Duplicated and figured it out. (Wasn't showing all results for me, just wrong ones. Was showing wherever the term was any of the fields instead of just the specified field I think.) Use the attached search.php file.

[removed: was buggy]
siteengineering
Member

Usergroup: Customer
Joined: Feb 16, 2005

Total Topics: 4
Total Comments: 21
Posted Mar 14, 2005 - 7:06 AM:

Thanks, but that's not working as expected. Is my understanding of these functions correct?

ALL OF THE WORDS
should return records for which all "words" in the search string are substrings of the specified field

ANY OF THE WORDS:
should return records for which any "word" (space delimited string) in the search string is a substring of the specified field

Example: separate searches for "contains" word "site" returns 2 records, "company" returns 2 records (1 duplicate of 1st search), "fishmarket" returns 1 new result. An "any of" search for "site company fishmarket" should return the union of these sets of results, which in this case is 4 records. Only 2 are being returned with the new search.php.

(Sidenote: typing a space after the last word causes all db records to be returned)

Thanks again for your efforts here.
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Mar 15, 2005 - 4:01 AM:

I think this finally solves things (including the sidenote).

Attached Files:
siteengineering
Member

Usergroup: Customer
Joined: Feb 16, 2005

Total Topics: 4
Total Comments: 21
Posted Mar 15, 2005 - 6:36 AM:

Thanks again. Sorry, though - there are still a few issues:

"Any of" almost works. Only one relatively minor exception that I could find... while a substring of a word is usually enough to give a match, this is not the case for the first word in the search field.

"All of" seems to be behaving very similarly to "any of". For example, on my page above, the search for "all of" "site company fishmarket" should yield no results. It actually gives four - same as "any of". I checked by html in case we'd put "or" instead of "and" but it's OK.

Thanks again Paul. Sorry to be a thorn in your side!
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Mar 16, 2005 - 5:04 AM:

http://links.webmastersite.net/search.php

title has all of the words 'webmaster resources' has 11 results and all look proper
title has any of the words 'webmaster resources' has 46 results

title has all of the words 'webmast resources' has 11 results
title has any of the words 'webmast resources' has 47 results

So, I can't see how you're getting your results.
siteengineering
Member

Usergroup: Customer
Joined: Feb 16, 2005

Total Topics: 4
Total Comments: 21
Posted Mar 16, 2005 - 9:32 AM:

I can't see any problems with the search.php you have running there, yet the issues on my installation are obvious. Sorry to ask this... please don't be insulted, but are you sure that you attached the latest version above?

Thanks again.
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
#10 - Quote - Permalink
Posted Mar 18, 2005 - 7:50 AM:

I don't have any other WSN Links versions on my computer (though I suppose it could be from another script), but here it is again.

Attached Files:
siteengineering
Member

Usergroup: Customer
Joined: Feb 16, 2005

Total Topics: 4
Total Comments: 21
#11 - Quote - Permalink
Posted Mar 18, 2005 - 10:25 AM:

Yep, that's the same file. It just won't work for us - no idea why and don't have the time to pour over the source. I've had to remove the "all words" option. It's still a great search tool without it. Anyway Paul, thanks for your time.
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



This thread is closed, so you cannot post a reply.