Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Highlighted
Developer
Posts: 528
Registered: ‎10-06-2009
My Device: 9800,BB Dev Alpha,z10 limited edition
My Carrier: Vodafone

How to implement a smart search that recognizes even typos

Hi,

 

I need to implement a smartsearch that can detect even typo. e.g if I type korbi it should also detect corvi,korvi .

 

Can somebody suggest an apporach?

Rujuta Trivedi
Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: How to implement a smart search that recognizes even typos

The easy part is having a FieldChangeListener on a text Field - then you get told whenever a key is entered and you can find out what the user has typed in.

 

The hard part is deciding what the user really meant.  This is not a Blackberry specific problem but a general problem.  But I suspect it involves searching a database for possible matches and making this search both very clever and very fast.

 

What options have you considered for doing this?

Developer
Posts: 528
Registered: ‎10-06-2009
My Device: 9800,BB Dev Alpha,z10 limited edition
My Carrier: Vodafone

Re: How to implement a smart search that recognizes even typos

Hi,

 

I thought to use autocompleteeditfield and include the words from database as filteredlist but don't know how to recognize what user is meant to type and display matching words

Rujuta Trivedi
Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: How to implement a smart search that recognizes even typos

"but don't know how to recognize what user is meant to type and display matching".  Just for clarification, I was just wondering if this is a BlackBerry related question?  You would have this problem trying to develop this functionality on another platform?

Developer
Posts: 528
Registered: ‎10-06-2009
My Device: 9800,BB Dev Alpha,z10 limited edition
My Carrier: Vodafone

Re: How to implement a smart search that recognizes even typos

My question is autocompletefield will help? or some other bb component

Rujuta Trivedi