Skip to content
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

Convert DROP INDEX SQL to pgroll operation #524

Merged
merged 6 commits into from
Dec 11, 2024
Merged

Conversation

ryanslade
Copy link
Collaborator

@ryanslade ryanslade commented Dec 11, 2024

Converts SQL in the following forms to the equivalent pgroll operation:

DROP INDEX foo
DROP INDEX schema.foo
DROP INDEX foo RESTRICT
DROP INDEX CONCURRENTLY foo
DROP INDEX IF EXISTS foo

The following forms are left as raw SQL operations since we do not support them in pgroll yet:

DROP INDEX foo CASCADE

Part of #504

pkg/sql2pgroll/drop.go Outdated Show resolved Hide resolved
Copy link
Collaborator

@andrew-farries andrew-farries left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍 , left some comments

pkg/sql2pgroll/drop.go Outdated Show resolved Hide resolved
pkg/sql2pgroll/drop.go Outdated Show resolved Hide resolved
pkg/sql2pgroll/drop_test.go Outdated Show resolved Hide resolved
pkg/sql2pgroll/drop.go Outdated Show resolved Hide resolved
@ryanslade
Copy link
Collaborator Author

@andrew-farries PTAL

@ryanslade ryanslade merged commit ac222a4 into main Dec 11, 2024
27 checks passed
@ryanslade ryanslade deleted the rs/sql2pgroll-drop-index branch December 11, 2024 13:27
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