The GitHub Actions job "Build and test" on spark.git has failed.
Run started by GitHub user HyukjinKwon (triggered by HyukjinKwon).

Head commit for run:
4e95738fdfc334c25f44689ff8c2db5aa7c726f2 / Daniel Tenedorio 
<[email protected]>
[SPARK-38336][SQL] Support DEFAULT column values in CREATE/REPLACE TABLE 
statements

### What changes were proposed in this pull request?

Extend CREATE TABLE and REPLACE TABLE statements to support columns with 
DEFAULT values. This information will be stored in the column metadata.

### Why are the changes needed?

This builds the foundation for future work (not included in this PR) to support 
INSERT INTO statements, which may then omit the default values or refer to them 
explicitly with the DEFAULT keyword, in which case the Spark analyzer will 
automatically insert the appropriate corresponding values in the right places.

Example:
```
CREATE TABLE T(a INT DEFAULT 4, b INT NOT NULL DEFAULT 5);
INSERT INTO T VALUES (1);
INSERT INTO T VALUES (1, DEFAULT);
INSERT INTO T VALUES (DEFAULT, 6);
SELECT * FROM T;
(1, 5)
(1, 5)
(4, 6)
```

### How was this patch tested?

This change is covered by new and existing unit test coverage as well as new 
INSERT INTO query test cases covering a variety of positive and negative 
scenarios.

Closes #35855 from dtenedor/default-cols-create-table.

Authored-by: Daniel Tenedorio <[email protected]>
Signed-off-by: Gengliang Wang <[email protected]>

Report URL: https://github.com/apache/spark/actions/runs/2045036826

With regards,
GitHub Actions via GitBox

Reply via email to