From e6f4b711a7e1f885a2200b22e40786cf0dacddcc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E5=B0=8F=E5=8C=97?= Date: Tue, 1 Sep 2020 15:50:53 +0800 Subject: [PATCH] fix order case (#3350) --- chainable_api.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chainable_api.go b/chainable_api.go index c8417a6d..ae2ac4f1 100644 --- a/chainable_api.go +++ b/chainable_api.go @@ -198,7 +198,7 @@ func (db *DB) Having(query interface{}, args ...interface{}) (tx *DB) { // Order specify order when retrieve records from database // db.Order("name DESC") -// db.Order(gorm.Expr("name = ? DESC", "first")) // sql expression +// db.Order(clause.OrderByColumn{Column: clause.Column{Name: "name"}, Desc: true}) func (db *DB) Order(value interface{}) (tx *DB) { tx = db.getInstance()