Added in Oracle Database 12c, SQL pattern matching (match_recognize) makes it easy to answer many questions that were hard-to-impossible with SQL.
But turning match_recognize clauses into reusable functions was tricky at best.
No more!
Added in 19.6, SQL macros enable you to define reusable code fragments. These return SQL that becomes part of your final SQL statement.
**********
AskTOM Office Hours offers free, monthly training and tips on how to make the most of Oracle Database, from Oracle product managers, developers and evangelists.
https://asktom.oracle.com/
Oracle Developers portal: https://developer.oracle.com/
Sign up for an Oracle Cloud trial: https://www.oracle.com/cloud/free/
This session will show you how you can combine SQL macros and match_recogize. Together these enable you to write generic functions answering common questions such as "find me all the consecutive rows".
Watch video Pattern Matching + SQL Macros = Pure SQL Awesomeness! online without registration, duration hours minute second in high quality. This video was added by user Oracle Developers 18 June 2020, don't forget to share it with your friends and acquaintances, it has been viewed on our site 11,089 once and liked it 62 people.