You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
412 B
20 lines
412 B
package archive |
|
|
|
import ( |
|
"context" |
|
"go-common/library/log" |
|
) |
|
|
|
const ( |
|
_inNetsafeSQL = "INSERT INTO netsafe (nid,md5) VALUES (?,?)" |
|
) |
|
|
|
// AddNetSafeMd5 fn |
|
func (d *Dao) AddNetSafeMd5(c context.Context, nid int64, md5 string) (rows int64, err error) { |
|
res, err := d.db.Exec(c, _inNetsafeSQL, nid, md5) |
|
if err != nil { |
|
log.Error("_inNetsafeSQL.Exec error(%v)", err) |
|
return |
|
} |
|
return res.RowsAffected() |
|
}
|
|
|