Skip to content

fix: Add warning for mysql2 client configuration for bigint #537

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ergofriend
Copy link

About

I would like to add a note about node-mysql2 settings for bigint columns.
There are some reasons.

while passing only the DSN automatically enables supportBigNumbers, it would be nice to provide care for cases where it is defined by the user

https://github.com/drizzle-team/drizzle-orm/blob/6ab1bbea566f3e2e048c6980038696e03d8e780a/drizzle-orm/src/mysql2/driver.ts#L151-L156

mysql-bigint's mapFromDriverValue expects a string

https://github.com/drizzle-team/drizzle-orm/blob/2677718/drizzle-orm/src/mysql-core/columns/bigint.ts#L95-L97

Related issues

drizzle-team/drizzle-orm#4119

Changes

before

https://orm.drizzle.team/docs/column-types/mysql#bigint

after

http://localhost:4321/docs/column-types/mysql#bigint

CleanShot 2025-04-06 at 15 25 08@2x

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.

1 participant