-
Notifications
You must be signed in to change notification settings - Fork 28.9k
[SPARK-7012][SQL] Add support for NOT NULL modifier for column definitions on DDLParser #8746
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@smola I have created this PR for SPARK-7012 |
|
Can one of the admins verify this patch? |
|
@sabhyankar Great! The implementation looks good. Could you add a test case for it? |
|
@smola Thanks for the review. I will add a test case for it and push another commit today. |
|
@smola I have added a test case for this. Let me know if you see anything else that needs to be changed or added. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can use withTempPath for this test. example
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @cloud-fan ! This makes it much cleaner. I have made the change in the latest commit.
|
@smola @cloud-fan Thanks again for the review guys. I have made the additional changes that were noted. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: !xxx.isDefined == xxx.isEmpty
|
LGTM |
|
Thanks again @cloud-fan I have pushed a new commit with the updates! |
|
Hi @smola - Is there anything else that you need me to check for this PR? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
improve this test case to make sure we really make that column not nullable, i.e. read the table out and check its schema.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sabhyankar Do you have time to modify this? I think that once the test is improved with @cloud-fan comment, the change is probably good to merge.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @smola @cloud-fan - I will take a look at the test case this week and update you guys
|
I am not sure if we should do it now because it is still possible to have nulls in a column defined as |
|
How about we close this PR for now and revisit it later? |
Add support for NOT NULL modifier for column definitions in DDLParser