Commit bdd2796
[SPARK-24251][SQL] Add analysis tests for AppendData.
## What changes were proposed in this pull request?
This is a follow-up to #21305 that adds a test suite for AppendData analysis.
This also fixes the following problems uncovered by these tests:
* Incorrect order of data types passed to `canWrite` is fixed
* The field check calls `canWrite` first to ensure all errors are found
* `AppendData#resolved` must check resolution of the query's attributes
* Column names are quoted to show empty names
## How was this patch tested?
This PR adds a test suite for AppendData analysis.
Closes #22043 from rdblue/SPARK-24251-add-append-data-analysis-tests.
Authored-by: Ryan Blue <[email protected]>
Signed-off-by: Wenchen Fan <[email protected]>1 parent 6c7bb57 commit bdd2796
File tree
3 files changed
+397
-13
lines changed- sql/catalyst/src
- main/scala/org/apache/spark/sql/catalyst
- analysis
- plans/logical
- test/scala/org/apache/spark/sql/catalyst/analysis
3 files changed
+397
-13
lines changedLines changed: 10 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2258 | 2258 | | |
2259 | 2259 | | |
2260 | 2260 | | |
2261 | | - | |
2262 | | - | |
| 2261 | + | |
| 2262 | + | |
2263 | 2263 | | |
2264 | 2264 | | |
2265 | 2265 | | |
| |||
2278 | 2278 | | |
2279 | 2279 | | |
2280 | 2280 | | |
2281 | | - | |
2282 | | - | |
| 2281 | + | |
| 2282 | + | |
| 2283 | + | |
2283 | 2284 | | |
2284 | 2285 | | |
2285 | 2286 | | |
| |||
2301 | 2302 | | |
2302 | 2303 | | |
2303 | 2304 | | |
| 2305 | + | |
| 2306 | + | |
| 2307 | + | |
| 2308 | + | |
2304 | 2309 | | |
2305 | 2310 | | |
2306 | 2311 | | |
2307 | 2312 | | |
2308 | | - | |
2309 | | - | |
| 2313 | + | |
2310 | 2314 | | |
2311 | 2315 | | |
2312 | 2316 | | |
| |||
Lines changed: 8 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
363 | 363 | | |
364 | 364 | | |
365 | 365 | | |
366 | | - | |
367 | | - | |
368 | | - | |
369 | | - | |
370 | | - | |
371 | | - | |
372 | | - | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
373 | 374 | | |
374 | 375 | | |
375 | 376 | | |
| |||
0 commit comments