Skip to content
Snippets Groups Projects
Commit a1eaaa60 authored by juanf's avatar juanf
Browse files

SSDM-2632 : Search with numeric properties, changed string for constant

SVN: 34880
parent f4565f73
No related branches found
No related tags found
No related merge requests found
......@@ -35,6 +35,7 @@ import ch.systemsx.cisd.openbis.generic.server.dataaccess.db.search.detailed.Num
import ch.systemsx.cisd.openbis.generic.shared.basic.dto.CompareType;
import ch.systemsx.cisd.openbis.generic.shared.basic.dto.DetailedSearchCriteria;
import ch.systemsx.cisd.openbis.generic.shared.basic.dto.IAssociationCriteria;
import ch.systemsx.cisd.openbis.generic.shared.dto.hibernate.SearchFieldConstants;
import ch.systemsx.cisd.openbis.generic.shared.dto.properties.EntityKind;
import ch.systemsx.cisd.openbis.generic.shared.translator.DtoConverters;
......@@ -203,7 +204,7 @@ public class LuceneQueryBuilder
String searchPattern = searchPatterns.get(i);
Analyzer analyzer = analyzers.get(i);
Query query = null;
if(!fieldName.equals("id") && type != null && (NumberRangeCalculator.isInteger(searchPattern) || NumberRangeCalculator.isReal(searchPattern))) {
if(!fieldName.equals(SearchFieldConstants.ID) && type != null && (NumberRangeCalculator.isInteger(searchPattern) || NumberRangeCalculator.isReal(searchPattern))) {
query = NumberRangeCalculator.getRangeQuery(type, fieldName, searchPattern);
} else {
query = parseQuery(fieldName, searchPattern, analyzer);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment