File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
src/main/java/org/nlpcn/es4sql/query/maker Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change 3
3
<modelVersion >4.0.0</modelVersion >
4
4
<groupId >org.nlpcn</groupId >
5
5
<artifactId >elasticsearch-sql</artifactId >
6
- <version >6.2.4.5 </version >
6
+ <version >6.2.4.6 </version >
7
7
<packaging >jar</packaging >
8
8
<description >Query elasticsearch using SQL</description >
9
9
<name >elasticsearch-sql</name >
Original file line number Diff line number Diff line change 4
4
import java .math .BigDecimal ;
5
5
import java .time .ZoneOffset ;
6
6
import java .util .*;
7
+ import java .util .stream .Collectors ;
7
8
8
9
import org .elasticsearch .common .xcontent .NamedXContentRegistry ;
9
10
import org .elasticsearch .common .xcontent .XContentParser ;
@@ -570,7 +571,8 @@ private HistogramAggregationBuilder histogram(MethodField field) throws SqlParse
570
571
*/
571
572
private RangeAggregationBuilder rangeBuilder (MethodField field ) {
572
573
573
- LinkedList <KVValue > params = new LinkedList <>(field .getParams ());
574
+ // ignore alias param
575
+ LinkedList <KVValue > params = field .getParams ().stream ().filter (kv -> !"alias" .equals (kv .key )).collect (Collectors .toCollection (LinkedList ::new ));
574
576
575
577
String fieldName = params .poll ().toString ();
576
578
You can’t perform that action at this time.
0 commit comments