You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@calcite.apache.org by "Fei Feng (JIRA)" <ji...@apache.org> on 2018/10/19 10:04:00 UTC
[jira] [Created] (CALCITE-2633) match_recognize all rows per match
return type bug
Fei Feng created CALCITE-2633:
---------------------------------
Summary: match_recognize all rows per match return type bug
Key: CALCITE-2633
URL: https://issues.apache.org/jira/browse/CALCITE-2633
Project: Calcite
Issue Type: Bug
Components: core
Affects Versions: 1.16.0
Environment: JDK 8,Calcite 1.6.0
Reporter: Fei Feng
Assignee: Julian Hyde
When using sql match recognize with flink cep ,something seems strange。
{color:#6a8759}SELECT *
{color}{color:#6a8759}FROM Ticker
{color}{color:#6a8759}MATCH_RECOGNIZE (
{color}{color:#6a8759} ORDER BY proctime
{color}{color:#6a8759} MEASURES
{color}{color:#6a8759} FIRST(DOWN.tstamp) AS top_tstamp,
{color}{color:#6a8759} LAST(DOWN.tstamp) AS bottom_tstamp
{color}{color:#6a8759} ALL ROWs PER MATCH
{color}{color:#6a8759} AFTER MATCH SKIP PAST LAST ROW
{color}{color:#6a8759} PATTERN (DOWN\{2,} LAST)
{color}{color:#6a8759} DEFINE
{color}{color:#6a8759} DOWN AS DOWN.price < PREV(DOWN.price) or PREV(DOWN.price) IS NULL,
{color}{color:#6a8759} LAST AS true
{color}{color:#6a8759}) AS T{color}
{color:#6a8759}With "AlLL ROWS PER MATCH",the result has 4 columns,the proctime is the first column.But with "ONE ROW PER MATCH",the result has 3 columns, and the proctime is not in the result set.
{color}
{color:#6a8759}Is this a bug?{color}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)