LucaCappelletti94 opened a new pull request, #2836: URL: https://github.com/apache/datafusion-sqlparser-rs/pull/2836
`CREATE TABLE p (a INT, CONSTRAINT nn NOT NULL a)` and `ALTER TABLE p ADD CONSTRAINT nn NOT NULL a NO INHERIT` failed with `Expected: PRIMARY, UNIQUE, FOREIGN, CHECK, or EXCLUDE, found: NOT`. Both forms now parse into `TableConstraint::NotNull`, which holds the optional name, the column and the `NO INHERIT` flag the way `CheckConstraint` does. A trailing `NOT VALID` in `ALTER TABLE` is already covered by `AddConstraint`. I added a `Dialect::supports_table_not_null_constraint` method to dispatch in which dialect this is supported. -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
