cancel
Showing results for 
Search instead for 
Did you mean: 

cmis search returns unexpected result.

begunrom
Champ in-the-making
Champ in-the-making
I execute the following cmis search
<blockcode>
select A.*, F.* FROM pmSmiley TongueroductTypeAspect AS A JOIN pm:drawing AS F ON A.cmisSmiley SurprisedbjectId = F.cmisSmiley SurprisedbjectId where A.pmSmiley TongueroductType ='—11'
</blockcode>

productTypeAspect is defined as
<blockcode>
<aspect name="pmSmiley TongueroductTypeAspect">
   <title>Product Type Aspect</title>
   <properties>
      <property name="pmSmiley TongueroductType">
         <title>Product Type</title>
         <type>d:text</type>
         <multiple>true</multiple>
      </property>
      <property name="pmSmiley Tongueroduct">
         <title>Product</title>
         <type>d:text</type>
         <multiple>true</multiple>
      </property>
      <property name="pm:item">
         <title>Item</title>
         <type>d:text</type>
         <multiple>true</multiple>
      </property>
   </properties>
</aspect>
</blockcode>

In Alfresco i have a number of documents that have a value set for pmSmiley TongueroductType.
Document 1 –> pmSmiley TongueroductType='—11'
Document 2 –> pmSmiley TongueroductType='—11.1'
Document 3 –> pmSmiley TongueroductType='abc'

If i execute the cmis search as specified above (where A.pmSmiley TongueroductType ='—11'), the result contains 2 documents (doc 1 and doc 2), while i only expected doc 1. I did not want '—11.1' to be returned.

How can i solve this?
3 REPLIES 3

kaynezhang
World-Class Innovator
World-Class Innovator
I think the problem is caused by lunene index token mechanism .You can try to define your pmSmiley TongueroductType property like following and rebuild index.

      <property name="pm:productType">
         <title>Product Type</title>
         <type>d:text</type>
         <multiple>true</multiple>
              <index enabled="true">
                      <tokenised>both</tokenised>
              </index>

      </property>

begunrom
Champ in-the-making
Champ in-the-making
Hi,

Thanks for your answer. It did change something… Now nothing is returned.

So unfortunately, this is not the answer to the problem.

Thanks for answering.

begunrom
Champ in-the-making
Champ in-the-making
Hi,

I started working. I guess i did not wait long enough.
Now correct results are being returned.

thanks.