-
Notifications
You must be signed in to change notification settings - Fork 640
feat(parser): support emit_mode #7783
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: TennyZhuang <[email protected]>
Codecov Report
@@ Coverage Diff @@
## main #7783 +/- ##
==========================================
- Coverage 71.74% 71.73% -0.02%
==========================================
Files 1107 1107
Lines 176388 176422 +34
==========================================
+ Hits 126558 126564 +6
- Misses 49830 49858 +28
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
||
#[test] | ||
fn parse_create_materialized_view_emit_immediately() { | ||
let sql = "CREATE MATERIALIZED VIEW myschema.myview EMIT IMMEDIATELY AS SELECT foo FROM bar"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought it should be part of the query i.e. inside the SELECT ...
clause. Did we change our mind?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we defined them on SELECT
, what's the semantic on subquery or CTE?
Currently, our conclusion is that we should ensure a mview or a sink can only have one emit option, the only way is defined on view.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
risingwavelabs/rfcs#30 defines the semantics in terms of relational algebra (i.e. given input set, what should be the output set), so the semantics is still well-defined for subqueries or CTEs.
Signed-off-by: TennyZhuang [email protected]
I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?
The parser part
Checklist
./risedev check
(or alias,./risedev c
)Refer to a related PR or issue link (optional)
#6042