fix: Add warning for mysql2 client configuration for bigint #537
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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