Take the 2-minute tour ×
User Experience Stack Exchange is a question and answer site for user experience researchers and experts. It's 100% free, no registration required.

When searching with ajax based suggesting field, how many letters should be typed before it starts to suggest results? 1,2,3..

share|improve this question
add comment

1 Answer

up vote 9 down vote accepted

Secondary rank

If you have another factor that can rank the results (e.g. "popularity", "kuakeli rank"):

  • start with the first letter
  • limit results by second rank, by picking the TOP N

(roughly: SELECT TOP 10 FROM Stuff WHERE Name LIKE "x*" ORDER BY Rank)

If you don't have that rank, you could still start after the first letter, but results aren't as useful. Still, there's no usability reason to start with a sorted list:

SELECT TOP 10 FROM Stuff WHERE Name LIKE "x*" ORDER BY Name

Performance reasons

Thee are a few traditional reasons for delaying the query:

  • Part of your query runs synchronous, and you have to limit UI blocking
  • You have to limit traffic / hits to the search provider

This is typically achieved by starting search if no key was pressed for the last few hundred milliseconds, or starting only after a minimum string length.


There's one case left (that I can think of) where starting after the N th key might improve usability: Misleading matches. If your search pool contains elements like this:

SDBXXFDR 1722 Lengthy
SDBXXFDR 1723 Still Lengthy
...   
SDBXXFDR 1799 Short
SOBXXFDR 1972 Lengthy with ripples

And you just type "S", the "SD" results may hide the SO one, the chance of pickign the wrong one is rather high. However, that sems very constructed, and I'm not sure if incremental search is a good solution at all if this would be a problem.

share|improve this answer
4  
Great answer, I just want to add that performance issues can be solved by delaying search for about 0.5 sec after keypress, so if user is typing smth, intermediate request will not be sent to server until he stops typing. –  Nikita Prokopov Mar 8 '11 at 13:12
    
@Nikita - thanks, I actually edited that out before the initial submit. I've added it again :) –  peterchen Mar 8 '11 at 16:32
1  
Really good, thank you. How about getting the results. Should the search look inside words or just the beginning of the word. fx. if search phrase is "sic" should it result fx. "basic" or just words beginning with "sic"? –  kuakeli Mar 9 '11 at 7:07
    
My recent conclusions: How well they match could be (or go into) the secondary rank - e.g. just list the "starts with sic" results first, then those just containing sic. –  peterchen Mar 9 '11 at 8:09
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.