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

With gorm and the sqlite driver that comes with gorm, when storing a number of the string type, if the number is very long, then the number is stored in the database as a scientific notation #7147

Open
lailailee opened this issue Aug 8, 2024 · 0 comments
Assignees
Labels
type:question general questions

Comments

@lailailee
Copy link

Your Question

With gorm (" Gorm.io /gorm") and the sqlite driver that comes with gorm (" Gorm.io /driver/sqlite"), when storing a number of the string type, if the number is very long, then the number is stored in the database as a scientific notation, which bothers me

The document you expected this should be explained

Expected answer

I want the result is: in the long list of type string of Numbers to the database, such as "88888888888888888888888", it will not be in the form of scientific notation, exists in the database

@lailailee lailailee added the type:question general questions label Aug 8, 2024
@lailailee lailailee changed the title 使用 gorm以及gorm自带的 sqlite驱动,在存储字符串类型的数字的时候,如果这个数字很长,那么这个数字会以科学记数的形式存储到数据库 With gorm (" Gorm.io /gorm") and the sqlite driver that comes with gorm (" Gorm.io /driver/sqlite"), when storing a number of the string type, if the number is very long, then the number is stored in the database as a scientific notation Aug 8, 2024
@lailailee lailailee changed the title With gorm (" Gorm.io /gorm") and the sqlite driver that comes with gorm (" Gorm.io /driver/sqlite"), when storing a number of the string type, if the number is very long, then the number is stored in the database as a scientific notation With gorm and the sqlite driver that comes with gorm, when storing a number of the string type, if the number is very long, then the number is stored in the database as a scientific notation Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:question general questions
Projects
None yet
Development

No branches or pull requests

2 participants