Is there a way to stem Roman numerals in sphinx, so that Roman numerals are synonymous with Arab numerals?
For example, the query “Mafia 2” would be the same as “Mafia II”, and vice versa.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can make it with wordforms.
Just write some script, translating Arab nums to Roman and make text file:
and so on… Then save in to /absolute/path/wordforms.txt and in your config in index section write:
That’s it. After reindexing if you search Mafia 2 sphinx find Mafia II for you. But it’s only one way translation (not so good for your question, but still useful) and better be used for things like this example from documentation:
Round 2
Better way is to prepare search query before the search starts and stay away from indexer 🙂
Your query:
or
That’s all. You only need to write some arab to roman convert function. You can find it googling something like