You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -78,7 +80,7 @@ A flow name must be a single-part name (that is resolved against the current pip
78
80
79
81
The [flowOperation](../logical-operators/CreateFlowCommand.md#flowOperation) of a [CreateFlowCommand](../logical-operators/CreateFlowCommand.md) command must be [InsertIntoStatement](../logical-operators/InsertIntoStatement.md).
80
82
81
-
!!! note
83
+
??? warning
82
84
Only `INSERT INTO ... BY NAME` flows are supported in [Spark Declarative Pipelines](index.md).
83
85
84
86
`INSERT OVERWRITE` flows are not supported.
@@ -91,46 +93,49 @@ In the end, `CreateFlowHandler` requests this [GraphRegistrationContext](#graphR
`CreateMaterializedViewAsSelectHandler` requests this [GraphRegistrationContext](#graphRegistrationContext) to register a [table](GraphRegistrationContext.md#registerTable) and a [flow](GraphRegistrationContext.md#registerFlow) (that backs the materialized view).
98
+
`CreateMaterializedViewAsSelectHandler` requests this [GraphRegistrationContext](#graphRegistrationContext) to [register a table](GraphRegistrationContext.md#registerTable) and a [flow](GraphRegistrationContext.md#registerFlow) (that backs the materialized view).
[processSqlQuery](#processSqlQuery) handles [CreateStreamingTable](../logical-operators/CreateStreamingTable.md) logical commands using `CreateStreamingTableHandler`.
101
103
102
-
```scala
103
-
handle(
104
-
cst: CreateStreamingTable,
105
-
queryOrigin: QueryOrigin):Unit
106
-
```
107
-
108
-
`handle` requests this [SqlGraphRegistrationContextState](#context) to [register a streaming table](GraphRegistrationContext.md#registerTable).
104
+
`CreateStreamingTableHandler` requests this [SqlGraphRegistrationContextState](#context) to [register a streaming table](GraphRegistrationContext.md#registerTable).
[processSqlQuery](#processSqlQuery) handles [CreateStreamingTableAsSelect](../logical-operators/CreateStreamingTableAsSelect.md) logical commands using `CreateStreamingTableAsSelectHandler`.
113
109
114
-
```scala
115
-
handle(
116
-
cst: CreateStreamingTableAsSelect,
117
-
queryOrigin: QueryOrigin):Unit
118
-
```
110
+
`CreateStreamingTableAsSelectHandler` requests this [SqlGraphRegistrationContextState](#context) to [register a streaming table](GraphRegistrationContext.md#registerTable) and the accompanying [flow](GraphRegistrationContext.md#registerFlow) (for the streaming table).
111
+
112
+
### CreateView { #CreateView }
113
+
114
+
[processSqlQuery](#processSqlQuery) handles [CreateView](../logical-operators/CreateView.md) logical commands using `CreatePersistedViewCommandHandler`.
115
+
116
+
`CreatePersistedViewCommandHandler` requests this [GraphRegistrationContext](#graphRegistrationContext) to [register a PersistedView](GraphRegistrationContext.md#registerView) and the accompanying [flow](GraphRegistrationContext.md#registerFlow) (for the `PersistedView`).
117
+
118
+
### CreateViewCommand { #CreateViewCommand }
119
119
120
-
`handle` requests this [SqlGraphRegistrationContextState](#context) to [register a streaming table](GraphRegistrationContext.md#registerTable) and the accompanying [flow](GraphRegistrationContext.md#registerFlow) (for the streaming table).
120
+
[processSqlQuery](#processSqlQuery) handles [CreateViewCommand](../logical-operators/CreateViewCommand.md) logical commands using `CreateTemporaryViewHandler`.
121
+
122
+
`CreateTemporaryViewHandler` requests this [GraphRegistrationContext](#graphRegistrationContext) to [register a TemporaryView](GraphRegistrationContext.md#registerView) and the accompanying [flow](GraphRegistrationContext.md#registerFlow) (for the `TemporaryView`).
123
+
124
+
### SetCatalogCommand { #SetCatalogCommand }
125
+
126
+
[processSqlQuery](#processSqlQuery) handles [SetCatalogCommand](../logical-operators/SetCatalogCommand.md) logical commands using `SetCatalogCommandHandler`.
127
+
128
+
`SetCatalogCommandHandler` requests this [SqlGraphRegistrationContextState](#context) to [setCurrentCatalog](SqlGraphRegistrationContextState.md#setCurrentCatalog) to the [catalogName](../logical-operators/SetCatalogCommand.md#catalogName) of the given [SetCatalogCommand](../logical-operators/SetCatalogCommand.md).
129
+
130
+
In the end, `SetCatalogCommandHandler` requests this [SqlGraphRegistrationContextState](#context) to [clearCurrentDatabase](SqlGraphRegistrationContextState.md#clearCurrentDatabase).
121
131
122
132
### SetCommand { #SetCommand }
123
133
124
134
[processSqlQuery](#processSqlQuery) handles [SetCommand](../logical-operators/SetCommand.md) logical commands using `SetCommandHandler`.
125
135
126
-
```scala
127
-
handle(
128
-
setCommand: SetCommand):Unit
129
-
```
130
-
131
-
`handle` requests this [SqlGraphRegistrationContextState](#context) to [setSqlConf](#setSqlConf) with the key-value pair of the given [SetCommand](../logical-operators/SetCommand.md) logical command.
136
+
`SetCommandHandler` requests this [SqlGraphRegistrationContextState](#context) to [setSqlConf](#setSqlConf) with the key-value pair of the given [SetCommand](../logical-operators/SetCommand.md) logical command.
132
137
133
-
??? note "RuntimeException"
138
+
??? warning "RuntimeException"
134
139
135
140
`handle` makes sure that the given `SetCommand` comes with a `key = value` pair or throws a `RuntimeException`:
136
141
@@ -146,17 +151,12 @@ handle(
146
151
147
152
[processSqlQuery](#processSqlQuery) handles [SetNamespaceCommand](../logical-operators/SetNamespaceCommand.md) logical commands using `SetNamespaceCommandHandler`.
148
153
149
-
```scala
150
-
handle(
151
-
setNamespaceCommand: SetNamespaceCommand):Unit
152
-
```
153
-
154
-
`handle` requests this [SqlGraphRegistrationContextState](#context) for the following:
154
+
`SetNamespaceCommandHandler` requests this [SqlGraphRegistrationContextState](#context) for the following:
155
155
156
156
* For a `database`-only, single-part namespace, [setCurrentDatabase](SqlGraphRegistrationContextState.md#setCurrentDatabase)
157
157
* For a `catalog.database` two-part namespace, [setCurrentCatalog](SqlGraphRegistrationContextState.md#setCurrentCatalog) and [setCurrentDatabase](SqlGraphRegistrationContextState.md#setCurrentDatabase)
158
158
159
-
??? note "SparkException"
159
+
??? warning "SparkException"
160
160
161
161
`handle` throws a `SparkException` for invalid namespaces:
A streaming table can be defined without a query, as streaming tables' data can be backed by standalone flows.
187
191
During a pipeline execution, it is validated that a streaming table has at least one standalone flow writing to the table, if no query is specified in the create statement itself.
0 commit comments