Github user albertostratio commented on a diff in the pull request:
https://github.com/apache/metamodel/pull/34#discussion_r36609637
--- Diff:
core/src/main/java/org/apache/metamodel/query/parser/SelectItemParser.java ---
@@ -113,10 +110,10 @@ public SelectItem findSelectItem(String expression)
throws MultipleSelectItemsPa
final int startParenthesis = expression.indexOf('(');
if (startParenthesis > 0 && expression.endsWith(")")) {
String functionName = expression.substring(0,
startParenthesis);
- function = FunctionType.get(functionName.toUpperCase());
+ function = FunctionTypeFactory.get(functionName.toUpperCase());
if (function != null) {
expression = expression.substring(startParenthesis + 1,
expression.length() - 1).trim();
- if (function == FunctionType.COUNT &&
"*".equals(expression)) {
+ if (function instanceof CountAggregateFunction &&
"*".equals(expression)) {
--- End diff --
Good point, I'll modify it. Thx!
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---