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 BSON column types #21

Open
Rodriguespn opened this issue Dec 10, 2024 · 0 comments
Open

Add BSON column types #21

Rodriguespn opened this issue Dec 10, 2024 · 0 comments
Assignees

Comments

@Rodriguespn
Copy link

Add support to BSON columns. To add a new column type:

Add the new column type to drizzle-orm/src/singlestore-core/columns

Add how the new type should be written on SIngleStore migration JSOn file in introspect-singlestore.ts

https://github.com/singlestore-labs/summer-hackathon-s2-drizzle-orm/blob/feature/add-bson-column-type/drizzle-kit/src/introspect-singlestore.ts#L10

https://github.com/singlestore-labs/summer-hackathon-s2-drizzle-orm/blob/feature/add-bson-column-type/drizzle-kit/src/introspect-singlestore.ts#L491

Add how the default value of the new type should be serialized: https://github.com/singlestore-labs/summer-hackathon-s2-drizzle-orm/blob/feature/add-bson-column-type/drizzle-kit/src/serializer/singlestoreSerializer.ts#L134

Add drizzle-kit to create a table with a column of the new type: https://github.com/singlestore-labs/summer-hackathon-s2-drizzle-orm/blob/feature/add-bson-column-type/drizzle-kit/tests/singlestore.test.ts#L512

Add a new type test with a table with a column of the new type or add a new column of the new type to the existing schemas in drizzle-orm/type-tests/singlestore/tables.ts: https://github.com/singlestore-labs/summer-hackathon-s2-drizzle-orm/blob/feature/add-bson-column-type/drizzle-orm/type-tests/singlestore/tables.ts#L33

Add it to one of the schemas on integration-tests/tests/singlestore/singlestore.test.ts

PR: singlestore-labs/s2-drizzle-orm-dev#8

@Rodriguespn Rodriguespn self-assigned this Dec 10, 2024
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

No branches or pull requests

1 participant