Skip to content

Conversation

@Jell
Copy link
Member

@Jell Jell commented Mar 21, 2025

when inlining a constraint it get created at the same time as the table, so there's never any row to be validated. This makes the NOT VALID option a no-op.

Since it's a no-op when inlined, it also leads to a diff when doing a schema load from the generated structure.sql, since the NOT VALID gets dropped.

So let's be pro-active about it, and just get rid of it as soon as the constraint gets inlined.

when inlining a constraint it get created at the same time as the
table, so there's never any row to be validated. This makes the `NOT
VALID` option a no-op.

Since it's a no-op when inlined, it also leads to a diff when doing a
schema load from the generated structure.sql, since the `NOT VALID`
gets dropped.

So let's be pro-active about it, and just get rid of it as soon as the
constraint gets inlined.
@Jell Jell merged commit 4e070f1 into main Mar 21, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants