utils_sql.go: add sqlScanner interface

This commit is contained in:
Adhityaa Chandrasekar 2019-12-27 17:12:46 -08:00
parent 042fda0e8c
commit 024859ff45

11
api/utils_sql.go Normal file
View File

@ -0,0 +1,11 @@
package main
import ()
// scanner is a database/sql abstraction interface that can be used with both
// *sql.Row and *sql.Rows.
type sqlScanner interface {
// Scan copies columns from the underlying query row(s) to the values
// pointed to by dest.
Scan(dest ...interface{}) error
}