From 0d9d7d4d98963127119018d23319af4ccceac676 Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Mon, 11 Mar 2024 07:54:52 -0400 Subject: [PATCH] refactor: store to 20 decimal places --- db/models/sc_price_history.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/db/models/sc_price_history.go b/db/models/sc_price_history.go index 998b186..2c2e9e0 100644 --- a/db/models/sc_price_history.go +++ b/db/models/sc_price_history.go @@ -18,7 +18,7 @@ func init() { type SCPriceHistory struct { gorm.Model CreatedAt time.Time `gorm:"index:idx_rate"` - Rate decimal.Decimal `gorm:"type:DECIMAL(10,6);index:idx_rate"` + Rate decimal.Decimal `gorm:"type:DECIMAL(10,20);index:idx_rate"` } func (SCPriceHistory) TableName() string {