资源说明:Scan
Scan standard lib database rows directly to structs or slices.
For the most comprehensive and up-to-date docs see the
Examples
Multiple Rows
db, err := sql.Open("sqlite3", "database.sqlite")
rows, err := db.Query("SELECT * FROM persons")
var persons []Person
err := scan.Rows(&persons, rows)
fmt.Printf("%#v", persons)
// []Person{
// {ID: 1, Name: "brett"},
// {ID: 2, Name: "fred"},
//
本源码包内暂不包含可直接显示的源代码文件,请下载源码包。