Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-2633

match_recognize all rows per match return type bug

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.16.0
    • None
    • core
    • None
    • JDK 8,Calcite 1.6.0

    Description

      When using sql  match recognize with flink cep ,something seems strange。

      SELECT * FROM Ticker

      MATCH_RECOGNIZE (    

            ORDER BY proctime    

             MEASURES           

                  FIRST(DOWN.tstamp) AS top_tstamp,           

                  LAST(DOWN.tstamp) AS bottom_tstamp           

             ALL ROWs PER MATCH           

            AFTER MATCH SKIP PAST LAST ROW     

             PATTERN (DOWN{2,} LAST)     

             DEFINE          

                  DOWN AS DOWN.price < PREV(DOWN.price) or PREV(DOWN.price) IS NULL,          

                   LAST AS true)

      AS T

      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.

      Is this a bug?

      Attachments

        Activity

          People

            Unassigned Unassigned
            ffjl1985 Fei Feng
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: