diff --git a/api/binancePrice.go b/api/binancePrice.go index c93c008..1f71ee2 100644 --- a/api/binancePrice.go +++ b/api/binancePrice.go @@ -27,7 +27,7 @@ func GetBinanceLatestPrice(symbol string) float64 { func GetBinanceLatestPrices(symbol string) []BinancePrice { var binancePrices []BinancePrice - global.DB.Where("symbol = ? order by id desc", symbol).Find(&binancePrices) + global.DB.Where("symbol = ? ", symbol).Order("id desc").Find(&binancePrices) //global.DB.Where("symbol = ? order by id desc", symbol).Limit(30).Find(&binancePrices) return binancePrices }