Hi Jörg,

Your approach won't work with the current implementation as the order clauses are not "analyzed", so changing the analyzer won't have any effect. It should be possible to add a NORMALIZE() function also in the SQL/SQL2 grammar, reusing the NormalizeSortComparator introduced by JCR-3443

Regards,
Cédric

Le 13/02/2013 18:39, Jörg von Frantzius a écrit :
Hi,

we've got the problem that our SQL2 queries with ORDER BY clauses on Strings do sort the Germans Umlauts at the end of the results, while Umlauts should be sorted like their equivalent characters without the accent (e.g. "ö" = "o").

According to https://issues.apache.org/jira/browse/JCR-3443, with Jackrabbit 2.5.3 it should be possible to have a normalize() function in XPath queries, but not in SQL2.

We're now thinking of modifying the Jackrabbit configuration, and in particular setting the "analyzer" param to the SearchIndex with a custom subclass of org.apache.lucene.analysis.standard.StandardAnalyzer, which makes use of a https://lucene.apache.org/core/old_versioned_docs/versions/3_0_3/api/core/org/apache/lucene/analysis/ASCIIFoldingFilter.html .

Does anybody per chance have an opinion whether that could be a viable approach?

Thanks for answers + regards,
Jörg


--
Cédric Damioli
Ametys CMS
http://www.ametys.org
http://www.anyware-services.com

Reply via email to