Skip to content
This repository has been archived by the owner on Sep 7, 2021. It is now read-only.
This repository is currently being migrated. It's locked while the migration is in progress.

Commit

Permalink
bug fix for SumsInt return empty slice (#542)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexfans authored and lunny committed Mar 25, 2017
1 parent 24a6ab1 commit 2cadda5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion session_sum.go
Expand Up @@ -123,7 +123,7 @@ func (session *Session) SumsInt(bean interface{}, columnNames ...string) ([]int6
session.queryPreprocess(&sqlStr, args...)

var err error
var res = make([]int64, 0, len(columnNames))
var res = make([]int64, len(columnNames), len(columnNames))
if session.IsAutoCommit {
err = session.DB().QueryRow(sqlStr, args...).ScanSlice(&res)
} else {
Expand Down

0 comments on commit 2cadda5

Please sign in to comment.