Search Integer Field

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-18-2008 04:34 AM
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
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
Labels:
- Labels:
-
Archive
2 REPLIES 2

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-18-2008 07:36 AM
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).
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).

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2008 10:19 AM
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
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
