Searching member list is still un-user-friendly

15 years 3 months ago #86895 by janeinpa
Maybe I'm doing something wrong. Here is my situation:

I have only one list on the site. I selected the "simple any word" search. I log just like all of our members will do (they are golfers, not technical wizards). I see the link for member list and I open it. I want to find Mary Messerschmidt, but I can't remember how to spell her last name. I know it starts with Mes so I type that in the last name field and hit enter. I think I should get all of the members whose last names begin with MES, but instead I get every single member who has mes in their name somewhere, like James or Limes or anything but what I'm looking for.

Do you see what I'm saying? So even though it finds "any" it's not useful because it doesn't return the matches with the best matches first. I still have to wade through a hundred names to find the one I want.

Maybe there is something I'm not doing. You can look at our site: www.ewgaphilly.com/new_15_site Create an account and try it. This is really the ONE thing our members will do with this list & it's not practical for at the moment. I really hope to be able to tweak this.

Please Log in to join the conversation.

15 years 3 months ago #87129 by beat
riko wrote:

Regarding the high resource usage as a reason for not implementing a single-box search, I guess that could be a good reason, although I can't seem to imagine a single MySQL statement causing such high resource usage. If it was a loop that checks one field at a time, maybe... but I imagine it'd be just one statement searching for one value in all fields.

Post edited by: riko, at: 2009/01/28 03:10


SQL is no magic...with non-exact searches, it can't use indexes (provided they exist), so MySQL would have to look not only through each row, but also through each column, and in each row/column through each field. On a 10'000 users site with 100 fields, that's 1'000'000 comparison, if each field has 10 chars on average that's 10'000'000 comparisons at minimum. Even with fast CPUs, this is incompatible load with shared hosting, for serving a single page... ;)

However I would need to read carefully through this thread to understand if there is any issue in here or not. Can you please reply with simpler shorter precise description with exact examples ? e.g. just 2-3 fields and one search criteria and list expected result v.s. returned ones ?

Beat - Community Builder Team Member

Before posting on forums: Read FAQ thoroughly -- Help us spend more time coding by helping others in this forum, many thanks :)
CB links: Our membership - CBSubs - Templates - Hosting - Forge - Send me a Private Message (PM) only for private/confidential info

Please Log in to join the conversation.

15 years 3 months ago #87180 by janeinpa
I don't know if I'm following you, but I think my request is quite simple.

We have a list of about 300 members. I want my users to be able to easily search for a member without knowing the exact spelling of the name. They are only searching the last name field.

So, if you want someone whose last name begins with W, I want to be able to type a "W" in the lastname field and hit seach. It should return all the people whose last names begin with W.

Right now it returns everyone whose last name has a W anywhere in it, which isn't helpful.

Even if you type 3 letters of the last name... let's say "Smi" for smith. You will get jasmine and a hundred other names that has smi in them somewhere.

Post edited by: janeinpa, at: 2009/01/29 20:18

Post edited by: janeinpa, at: 2009/01/29 20:19

Please Log in to join the conversation.

15 years 3 months ago #87185 by riko
I think janeinpa is asking for something where, if you perform a search for " LIKE '%smi%' " you actually get the results of " LIKE 'smi%' " first, then " LIKE '%smi%' " afterwards, while not repeating any results from the first part. So, if you search for "Ris" instead of getting:

Boris
Chris
Christian
Christina
Griswald
Harris
Kristin
Risa
Trisha
Tristin
Warris

You get:

Risa
Boris
Chris
Christian
Christina
Griswald
Harris
Kristin
Trisha
Tristin
Warris

One possible solution is to have the "lastname" field be first in one of the columns, so you could sort that column to sort the list by lastname. But that would put constraints on how your userlists look.

Regarding beat's response about SQL performance, I agree that would be the case for such a large memberlist with so many fields. In my case, I'm talking about under 3000 members with 20 or 30 fields. I tried it out by adding my own search box to the user list page, then hijacking $tablesWhereSQL in comprofiler.php whenever my search box was being used. (I also used some js to disable my search box when the normal search options were displayed, and enabling it when the normal search options were hidden. Kind of like a toggle between "simple search" and "advanced search".) It didn't seem any slower than normal searches, and as far as user interaction is concerned, is faster than having to click a "Search" link to bring up the search options and identifying which field(s) to search, at least for simple searches. Maybe this could be an option for sites with moderate number of users and fields.

Post edited by: riko, at: 2009/01/29 21:22

Please Log in to join the conversation.

15 years 3 months ago #87195 by janeinpa
Yes, I think that's it. I want it to return the "Best" matches first. It can add all the other stuff at the end if it likes. I'm not a programmer, so I don't have a clue how hard this is to accomplish. However, I've been on many sites where I have searched in exactly the way I'm describing. It is the natural, common sense way users would try to search.

As in your example, I Search RIS, I should get:

Mary Riser
Joe Ristover
Ed Risy
then...
Fred erister
Ann lamerista
etc.


I'm not sure how to do what you're saying about the last name in the first column. Currently I have the avatar in the first column, then formatted name, but I can change it. What do I do once I put it in the first column?

Post edited by: janeinpa, at: 2009/01/29 23:06

Please Log in to join the conversation.

15 years 3 months ago #87200 by riko
About the sort idea I mentioned earlier, sorry, I was under the wrong impression that search results could be sorted. Apparently they can't. So, we're back to square one. I don't think this can be done via any settings in the current CB. It'll probably have to be an enhancement in a future version. But I'm not on the CB team, so hopefully one of them can address this.

Post edited by: riko, at: 2009/01/30 00:08

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.237 seconds

Facebook Twitter LinkedIn