Skip to content

beiping0/test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

在 dao 层中遇到一个 sql.ErrNoRows? 答案:应该 代码: func (o *querySet) One(container interface{}, cols ...string) error { o.limit = 1 num, err := o.orm.alias.DbBaser.ReadBatch(o.orm.db, o, o.mi, o.cond, container, o.orm.alias.TZ, cols) if err != nil { return err } if num == 0 { return ErrNoRows }

if num > 1 {
    return ErrMultiRows
}
return nil

}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published