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

Add check "Don't use serial" #317

Open
mfvanek opened this issue Nov 21, 2023 · 8 comments
Open

Add check "Don't use serial" #317

mfvanek opened this issue Nov 21, 2023 · 8 comments
Assignees
Labels
enhancement New feature or request

Comments

@mfvanek
Copy link
Owner

mfvanek commented Nov 21, 2023

@mfvanek mfvanek added enhancement New feature or request help wanted Extra attention is needed good first issue Good for newcomers labels Nov 21, 2023
@manumafe98
Copy link

Hi @mfvanek I would like to work on this one!

@mfvanek
Copy link
Owner Author

mfvanek commented Jan 8, 2024

Hi @manumafe98 !
Sure! Feel free to contribute

@mfvanek mfvanek removed help wanted Extra attention is needed good first issue Good for newcomers labels Jan 8, 2024
@manumafe98
Copy link

Thanks @mfvanek! I'm needing a bit more information on this one, the goal is to make a test that checks that serial is not being used?

@mfvanek
Copy link
Owner Author

mfvanek commented Jan 8, 2024

@manumafe98
The goal is to help developers migrate to the new syntax when defining primary keys. Instead of old smallserial/serial/bigserial new "generated as identity" syntax should be used.

You need to implement a new sql query to find cases of using old syntax. As example you can use https://github.com/mfvanek/pg-index-health-sql/blob/master/sql/non_primary_key_columns_with_serial_types.sql

Then you need to implement a Java layer above new sql query. A new class have to appear in https://github.com/mfvanek/pg-index-health/tree/master/pg-index-health/src/main/java/io/github/mfvanek/pg/checks/host. See https://github.com/mfvanek/pg-index-health/blob/master/pg-index-health/src/main/java/io/github/mfvanek/pg/checks/host/ColumnsWithSerialTypesCheckOnHost.java as example

@mfvanek
Copy link
Owner Author

mfvanek commented Apr 13, 2024

Hi @manumafe98
Any updates?

@manumafe98
Copy link

Hey @mfvanek I'm going to unassign it, currently i'm a bit swamped and I think there is a lot that i should learn to make progress on this issue currently, thanks for the information, maybe I will give it a try in the future if it still open!

@manumafe98 manumafe98 removed their assignment Apr 14, 2024
@mfvanek mfvanek added help wanted Extra attention is needed good first issue Good for newcomers labels Apr 27, 2024
@mfaulther
Copy link
Collaborator

Hi @mfvanek
May i take this issue ?

@mfvanek mfvanek removed help wanted Extra attention is needed good first issue Good for newcomers labels May 4, 2024
@mfvanek
Copy link
Owner Author

mfvanek commented May 4, 2024

Hi @mfvanek May i take this issue ?

Yes, sure! I appreciate your help.

@mfvanek mfvanek added this to the 0.11.1 milestone May 4, 2024
@mfvanek mfvanek removed this from the 0.11.2 milestone May 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants