# Syntax error for "all rows per match with unmatched rows" for match\_recognize sql statement

**URL:** <https://forums.toadworld.com/t/syntax-error-for-all-rows-per-match-with-unmatched-rows-for-match-recognize-sql-statement/53608>\
**Category:** Toad for Oracle & DevOps Toolkit\
**Created:** [September 7, 2021, 5:43pm UTC](https://forums.toadworld.com/t/syntax-error-for-all-rows-per-match-with-unmatched-rows-for-match-recognize-sql-statement/53608 "2021-09-07T17:43:23Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jbirkenstamm](https://avatars.discourse-cdn.com/v4/letter/j/94ad74/32.png) [@jbirkenstamm](https://forums.toadworld.com/u/jbirkenstamm)\
**Post date:** [September 7, 2021, 5:43pm UTC](https://forums.toadworld.com/t/syntax-error-for-all-rows-per-match-with-unmatched-rows-for-match-recognize-sql-statement/53608/1 "2021-09-07T17:43:23Z")

</div>

Statement executes fine (version 14.2), but there is a red circle ! mark (syntax error) in the editor gutter on the WITH keyword for the following statement:

SELECT \*  
FROM Running\_Log MATCH\_RECOGNIZE  
(  
ORDER BY Run\_Date  
MEASURES FIRST (Run\_Date) AS Start\_Date  
,COUNT (_) AS Days\_So\_Far  
,FINAL COUNT (_) AS Total\_Days  
,CLASSIFIER () AS Variable  
ALL ROWS PER MATCH WITH UNMATCHED ROWS  
PATTERN (Init Consecutive{2})  
DEFINE Consecutive AS Run\_Date = (PREV (Run\_Date) + 1)  
);
