Hi All,
Is there any way to make use of non english words like "español" as fulltext in Querybuilder API?
Solved! Go to Solution.
Views
Replies
Total Likes
Hi @binoyp,
Full text search will be able to find español in the content irrespective of language. Please see below OOTB groovy script which is able to find all the references of español in the content
def predicates = [
"path": "/content",
"fulltext": "español"
]
def query = createQuery(predicates)
query.hitsPerPage = 10
def result = query.result
println "${result.totalMatches} hits, execution time = ${result.executionTime}s\n--"
result.hits.each { hit ->
println "hit path = ${hit.node.path}"
}
Please check if UTF-8 is enabled in Apache Sling Request Parameter Handling configuration.
The QueryBuilder works on the given predicates. If you're using non-english words and searching in those specific locales, it should work. For example: searching "español" in /content/yourproject/es/*.
What problem are you facing or whats the requirement?
Thanks,
Singaiah
Views
Replies
Total Likes
Views
Replies
Total Likes
Views
Replies
Total Likes
Hi @binoyp,
Full text search will be able to find español in the content irrespective of language. Please see below OOTB groovy script which is able to find all the references of español in the content
def predicates = [
"path": "/content",
"fulltext": "español"
]
def query = createQuery(predicates)
query.hitsPerPage = 10
def result = query.result
println "${result.totalMatches} hits, execution time = ${result.executionTime}s\n--"
result.hits.each { hit ->
println "hit path = ${hit.node.path}"
}
Please check if UTF-8 is enabled in Apache Sling Request Parameter Handling configuration.
Views
Replies
Total Likes
Views
Replies
Total Likes
Views
Replies
Total Likes
Views
Replies
Total Likes