pluralize and singularize for spanish language
Posted
by
el_quick
on Stack Overflow
See other posts from Stack Overflow
or by el_quick
Published on 2011-01-05T18:30:32Z
Indexed on
2011/01/06
4:54 UTC
Read the original article
Hit count: 201
Hello, sorry for my english...
I have a rails application developed to spain, therefore, all content is in spanish, so, I have a search box to search in a mysql database, all rows are in spanish, I'd like to improve my search to allow to users to search keywords in singular or plural form, for example:
keyword: patatas
found: patata
keyword: veces
found: vez
keyword: vez
found: veces
keyword: actividades
found: actividad
In english, this could be relatively easy with help of singularize and pluralize methods ...
where `searching_field` like '%singularized_keyword%' or `searching_field` like '%pluralized_keyword%'
But, for spanish....
Some help?
Thanks!
© Stack Overflow or respective owner