cancel
Showing results for 
Search instead for 
Did you mean: 

Search Integer Field

bgl
Champ on-the-rise
Champ on-the-rise
Hi,

I have a property of an aspect that is an integer. I then want to search contents like "all contents that have this field larger than 10".

Is is supported out of the box or do I have to customize Alfresco ? (any hint for doing this are welcome if not supported  :wink: )

thank you

Boris
2 REPLIES 2

bgl
Champ on-the-rise
Champ on-the-rise
Part of answer : integer indexing is supported (they are encoded in a special way in lucene index - see org.alfresco.repo.search.impl.lucene.analysis.NumericEncoder -).

But it seems that there are no way -out of the box- to use some shortcuts like field > 5 (that could be translated in the back end as a range query for lucene).

andy
Champ on-the-rise
Champ on-the-rise
Hi

This is supported in the CMIS SQL 92 query language.
It is not part of the lucene query parser.

However, we have added open ended ranges in the form

@cm:woof[10 TO MAX]
@cm:woof[MIN TO 10]

MAX can be anything that does not parse to a number.

Andy