Exemple #1
0
func IsImportedEquipmentInfo(file string, dbm *gorp.DbMap) (int64, error) {
	q := sq.Select(
		"count(*)",
	).From(
		"EquipmentInfo",
	).Where(
		sq.Eq{"File": file},
	)

	sql, args, err := q.ToSql()
	if err != nil {
		return -1, err
	}

	return dbm.SelectInt(sql, args...)
}