Skip to content

database/sql: document that it is valid to have multiple Rows for the same Stmt #3734

@alexbrainman

Description

@alexbrainman
I think, this:

stmt, _ := db.Prepare("select name from people")
defer stms.Close()
rows1, _ := stmt.Query()
rows2, _ := stmt.Query()
// do things with rows1 and rows2 in any order

is valid.

Alex

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions