diff --git a/dao/config_dao.go b/dao/config_dao.go index e71778b..7d381a4 100644 --- a/dao/config_dao.go +++ b/dao/config_dao.go @@ -10,7 +10,7 @@ func GetConfig(db *sqlx.DB, configType, key string) (config *model.NewConfig, er configs []*model.NewConfig ) sql := ` - SELECT * FROM new_config WHERE type = ? AND key = ? + SELECT * FROM new_config WHERE ` + "`type`" + ` = ? AND key = ? ` sqlParams := []interface{}{configType, key} if err = db.Select(&configs, sql, sqlParams...); err == nil && len(configs) > 0 {