QueryStringStmt executes a single query that return rows, but don't modify database.
(query string)
| 1289 | |
| 1290 | // QueryStringStmt executes a single query that return rows, but don't modify database. |
| 1291 | func (db *DB) QueryStringStmt(query string) ([]*command.QueryRows, error) { |
| 1292 | r := &command.Request{ |
| 1293 | Statements: []*command.Statement{ |
| 1294 | { |
| 1295 | Sql: query, |
| 1296 | }, |
| 1297 | }, |
| 1298 | } |
| 1299 | return db.Query(r, false) |
| 1300 | } |
| 1301 | |
| 1302 | // QueryStringStmtWithTimeout executes a single query that return rows, but don't modify database. |
| 1303 | // It also sets a timeout for the query. |