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

Martijn Visser commented on FLINK-7496:
---------------------------------------

The check from FLINK-7147 still matters for relaxed contiguity: with it 
removed, Dawid's case from #4296 (c a* d? e with followedBy, input c a a d a e) 
again returns the extra match c a1 a2 e. That match is already reachable today, 
because times(0, 1) and times(0, 3) make the pattern optional without going 
through optional().

For strict contiguity, which is all MATCH_RECOGNIZE builds, the check is not 
needed. Without it, A+ B? C compiles to the same NFA as times(0, 1). On all 
sequences up to length 8, Flink gave the same result for each lifted pattern 
and its accepted {0,3} spelling wherever Trino, Oracle and the standard did. 
The remaining differences come from FLINK-41692, FLINK-41693 and FLINK-31328. 
No flink-cep test fails without the check.

> Support greedy quantifier followed by an optional pattern
> ---------------------------------------------------------
>
>                 Key: FLINK-7496
>                 URL: https://issues.apache.org/jira/browse/FLINK-7496
>             Project: Flink
>          Issue Type: Improvement
>          Components: Library / CEP
>    Affects Versions: 1.4.0
>            Reporter: Dian Fu
>            Priority: Not a Priority
>              Labels: auto-deprioritized-major, auto-deprioritized-minor
>
> FLINK-7147 has introduced the support of greedy quantifier. While currently 
> it doesn't work when greedy quantifier pattern is followed by an optional 
> pattern.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to