File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1060,6 +1060,20 @@ pub trait Dialect: Debug + Any {
10601060 fn supports_space_separated_column_options ( & self ) -> bool {
10611061 false
10621062 }
1063+
1064+ /// Returns true if the dialect supports `ADD <table_constraint> [NOT VALID]` in `ALTER TABLE` statements.
1065+ ///
1066+ /// -[PostgreSQL](https://www.postgresql.org/docs/17/sql-altertable.html)
1067+ fn supports_constraint_not_validation ( & self ) -> bool {
1068+ false
1069+ }
1070+
1071+ /// Returns true if the dialect supports `VALIDATE CONSTRAINT <constraint_name>` in `ALTER TABLE` statements.
1072+ ///
1073+ /// -[PostgreSQL](https://www.postgresql.org/docs/17/sql-altertable.html)
1074+ fn supports_validate_constraint ( & self ) -> bool {
1075+ false
1076+ }
10631077}
10641078
10651079/// This represents the operators for which precedence must be defined
Original file line number Diff line number Diff line change @@ -258,4 +258,12 @@ impl Dialect for PostgreSqlDialect {
258258 fn supports_set_names ( & self ) -> bool {
259259 true
260260 }
261+
262+ fn supports_constraint_not_validation ( & self ) -> bool {
263+ true
264+ }
265+
266+ fn supports_validate_constraint ( & self ) -> bool {
267+ true
268+ }
261269}
You can’t perform that action at this time.
0 commit comments