You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (Jira)" <ji...@apache.org> on 2025/01/12 19:17:00 UTC

[jira] [Commented] (CALCITE-6780) Trim function failed in SqlOperatorTest when the expression is TRIM(string)

    [ https://issues.apache.org/jira/browse/CALCITE-6780?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17912294#comment-17912294 ] 

Julian Hyde commented on CALCITE-6780:
--------------------------------------

The summary implies that TRIM only fails when called from SqlOperatorTest. I doubt that this is the case. If so, please change the summary.

> Trim function failed in SqlOperatorTest when the expression is TRIM(string)
> ---------------------------------------------------------------------------
>
>                 Key: CALCITE-6780
>                 URL: https://issues.apache.org/jira/browse/CALCITE-6780
>             Project: Calcite
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 1.38.0
>            Reporter: ZheHu
>            Assignee: ZheHu
>            Priority: Minor
>
> When running the following test in SqlOperatorTest,
> {code:java}
> f.checkString("trim(' aAa ')", "aAa", "VARCHAR(5) NOT NULL");
> {code}
> it throws "java.lang.StringIndexOutOfBoundsException: begin 8, end 21, length 17", which comes from buildQuery2() in AbstractSqlTester.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)