dtenedor opened a new pull request, #36583:
URL: https://github.com/apache/spark/pull/36583

   ### What changes were proposed in this pull request?
   
   Support JSON scans when the table schema has associated DEFAULT column 
values.
   
   Example:
   
   ```
   create table t(i int) using json;
   insert into t values(42);
   alter table t add column s string default concat('abc', def');
   select * from t;
   > 42, 'abcdef'
   ```
   
   Interesting note: JSON does not distinguish between NULL values and the 
absence of values. Therefore inserting NULL and then selecting back the same 
column yields the default value (if any), since the insert did not change any 
storage.
   
   ### Why are the changes needed?
   
   This change makes it easier to build, query, and maintain tables backed by 
JSON data.
   
   ### Does this PR introduce _any_ user-facing change?
   
   Yes.
   
   ### How was this patch tested?
   
   This PR includes new test coverage.


-- 
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: reviews-unsubscr...@spark.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to