내 커뮤니티 업적 표시줄을 확대합니다.

Submissions are now open for the 2026 Adobe Experience Maker Awards.

Mark Solution

활동이 없어 이 대화는 잠겼습니다. 새 게시물을 작성해 주세요.

해결됨

How to set character encoding in query builder API to read Russian locale content

Avatar

Level 4

Hi All,

       We are using the below query builder API to read CQ page content information. But in our nodes we have Russian text as node property values. When we read using the below code, we are getting ??????? instead of actual value.

How to set character encoding in query builder API ?

Map<String,String> map=new HashMap<String,String>();            
            map.put("property", "jcr:primaryType");
            map.put("property.or", "true");
            map.put("property.1_value", "cq:PageContent");
            map.put("property.2_value", "dam:AssetContent");
            map.put("p.limit","-1");

            adminSession = slingRepository.loginAdministrative(null);

            query = builder.createQuery(PredicateGroup.create(map), adminSession);
            result = query.getResult();

Regards

Nivas

1 채택된 해결책 개

Avatar

정확한 답변 작성자:
Level 10

Localization context needs to be set. Ex:-  <cq:setContentBundle language='' />

원본 게시물의 솔루션 보기

2 답변 개

Avatar

정확한 답변 작성자:
Level 10

Localization context needs to be set. Ex:-  <cq:setContentBundle language='' />

Avatar

Level 4

Hi Sham,

             Thanks for your quick reply, but the example you provided is for JSP. But we don't have any JSP, in java we are reading the page content using Query Builder API. How do we retrieve the localized content in java.

 

Regards

Nivas