lsyldliu commented on code in PR #20653: URL: https://github.com/apache/flink/pull/20653#discussion_r962596397
########## docs/content/docs/dev/table/sql/create.md: ########## @@ -513,6 +513,46 @@ If you provide no like options, `INCLUDING ALL OVERWRITING OPTIONS` will be used **NOTE** The `source_table` can be a compound identifier. Thus, it can be a table from a different catalog or database: e.g. `my_catalog.my_db.MyTable` specifies table `MyTable` from catalog `MyCatalog` and database `my_db`; `my_db.MyTable` specifies table `MyTable` from current catalog and database `my_db`. +### `AS` + +The AS clause is a variation of SQL features (Feature T172, “AS subquery clause in table definition”). +The clause can be used to create a table based on the given query expression. It will be more user-friendly and reduce the cost for user to manually spell complex table creation statements. +You can use this clause in stream and batch mode. + +Consider the example statement below: + +```sql +CREATE TABLE ctas_hudi +WITH ( + 'connector' = 'hudi' Review Comment: Please use the built-in jdbc connector and fill in the required options as examples, such as: ```sql WITH ( 'connector' = 'jdbc', 'url' = 'jdbc:mysql://mysqlhost:3306/customerdb' ) ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org