[
https://issues.apache.org/jira/browse/CALCITE-6145?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17799123#comment-17799123
]
Julian Hyde commented on CALCITE-6145:
--------------------------------------
I agree with [~asolimando]. The dev list is a good place to start with just
about every question. Ideally questioners are respectful of everyone's time -
your question about the right forum is evidence that you are already thinking
in that way - but the community will never criticize someone for asking a
'dumb' question.
Your question about {{variablesSet}} in {{LogicalJoin}} would be a great one
for dev. Because it's a mailing list, your question and the answers to it will
go into the searchable archive and will help the next person who has the same
question.
> Function 'TRIM' without parameters throw NullPointerException
> -------------------------------------------------------------
>
> Key: CALCITE-6145
> URL: https://issues.apache.org/jira/browse/CALCITE-6145
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.36.0
> Reporter: SimonAlexs
> Priority: Major
> Labels: newbie
>
> When use sql as follow, trim without parameters, it throws
> java.lang.NullPointerException.
> {code:java}
> select trim(){code}
> Error position is org.apache.calcite.sql.SqlOperator#constructArgNameList.
> Source code is below. Line 5 "operand.getKind()" results in this exception.
>
> {code:java}
> protected @Nullable List<String> constructArgNameList(SqlCall call) {
> // If any arguments are named, construct a map.
> final ImmutableList.Builder<String> nameBuilder = ImmutableList.builder();
> for (SqlNode operand : call.getOperandList()) {
> if (operand.getKind() == SqlKind.ARGUMENT_ASSIGNMENT) {
> final List<SqlNode> operandList = ((SqlCall) operand).getOperandList();
> nameBuilder.add(((SqlIdentifier) operandList.get(1)).getSimple());
> }
> }
> ImmutableList<String> argNames = nameBuilder.build();
> if (argNames.isEmpty()) {
> return null;
> } else {
> return argNames;
> }
> } {code}
>
> Should it throw an exact description?
--
This message was sent by Atlassian Jira
(v8.20.10#820010)