You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@iotdb.apache.org by "Yuan Tian (Jira)" <ji...@apache.org> on 2022/11/15 10:58:00 UTC

[jira] [Assigned] (IOTDB-4934) [UDF]attribute is null without quote, return 500

     [ https://issues.apache.org/jira/browse/IOTDB-4934?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Yuan Tian reassigned IOTDB-4934:
--------------------------------

    Assignee: 李伟豪  (was: Yuan Tian)

> [UDF]attribute is null without quote, return 500 
> -------------------------------------------------
>
>                 Key: IOTDB-4934
>                 URL: https://issues.apache.org/jira/browse/IOTDB-4934
>             Project: Apache IoTDB
>          Issue Type: Bug
>    Affects Versions: 0.14.0-SNAPSHOT
>            Reporter: changxue
>            Assignee: 李伟豪
>            Priority: Minor
>         Attachments: image-2022-11-15-10-38-05-254.png, normla-udf-0.14-SNAPSHOT.jar
>
>
> [UDF]attribute is null without quote, return 500 
> 不应该报错500
> reproduction:
> {code}
> create function count_sec as "com.timecho.udf.normal.TestSessionTimeWindowAccessStrategy";
> CREATE DATABASE root.udf;
> CREATE TIMESERIES root.udf.d1.s1 WITH DATATYPE=text, ENCODING=PLAIN;
> CREATE TIMESERIES root.udf.d1.s2 WITH DATATYPE=text, ENCODING=PLAIN;
> insert into root.udf.d1 (time, s1, s2) values (1, 'udf', 'trigger'),(2, 'some' , 'old'),(3, null, 'trigger'),(9, 'udf', 'new'),(5, 'woman', 'udf'),(12, 'trigger', null),(14, 'udf', 14),(18, 'udf', 16),(21, 'trigger', 18),(24, 'udf', 20);
> select count_sec(s1, 'max_interval'=1, 'standard'=null) from root.udf.d1;
> select count_sec(s1, 'max_interval'=1, 'standard'=NULL) from root.udf.d1;
> {code}
> error message:
> {code}
> IoTDB> select count_sec(s1, 'max_interval'=4, 'standard'=null) from root.udf.d1;
> Msg: 500: [INTERNAL_SERVER_ERROR(500)] Exception occurred: "select count_sec(s1, 'max_interval'=4, 'standard'=null) from root.udf.d1". executeStatement failed. org.apache.iotdb.db.mpp.plan.expression.leaf.NullOperand cannot be cast to org.apache.iotdb.db.mpp.plan.expression.leaf.ConstantOperand{code}
>  !image-2022-11-15-10-38-05-254.png! 



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