• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Search : Exactly match or "begins with" ?

 
Daniel Breitner
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello everybody,

I think I am now at 95 % complete and I am translating my design decisions to english and read over the instructions again.

I stumbled about this sentence :

It must allow the user to search the data for all records, or for records where the name and/or location fields exactly match values specified by the user.


This is a contrast to the DB interface which reads

A non-null value in criteria[n] matches any field value that begins with criteria[n].



Is it possible to argue for the version of the DB interface (search all records that begin with ...) even though the instructions say MUST exactly match ?
 
Roel De Nijs
Sheriff
Posts: 10662
144
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Daniel,

Have a look at this thread.

Kind regards,
Roel
 
Daniel Breitner
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It must allow the user to search the data for all records, or for records where the name and/or location fields exactly match values specified by the user.



I interpret this as follows:

The User must be able to search for exact matches. When only the interface from db (which uses startsWith) is supported, the User is only able to search for exact matches if he types in the complete name of the room to rent.

For example : Lighthouse

But what if there is another room called Lighthouse2 ? Then the user is no more able to search for an exact match.

On the other way round, there is no requirement stating that the User should be able to do a "fuzzy" search

=> This leads to the assumption, that the best solution is to implement the server like the DB interface says with "startsWith" and then filter out (in the GUI or business implementation) all those that are no exact matches.
 
Roel De Nijs
Sheriff
Posts: 10662
144
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Daniel,

the best solution is to implement the server like the DB interface says with "startsWith" and then filter out (in the GUI or business implementation) all those that are no exact matches.
Exactly how I implemented it.

Kind regards,
Roel
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic