(ctx context.Context, arg SelectMetricsSinceParams)
| 365 | } |
| 366 | |
| 367 | func (q *Queries) SelectMetricsSince(ctx context.Context, arg SelectMetricsSinceParams) ([]Metric, error) { |
| 368 | rows, err := q.query(ctx, q.selectMetricsSinceStmt, selectMetricsSince, arg.ID, arg.Limit) |
| 369 | if err != nil { |
| 370 | return nil, err |
| 371 | } |
| 372 | defer rows.Close() |
| 373 | var items []Metric |
| 374 | for rows.Next() { |
| 375 | var i Metric |
| 376 | if err := rows.Scan(&i.ID, &i.Data); err != nil { |
| 377 | return nil, err |
| 378 | } |
| 379 | items = append(items, i) |
| 380 | } |
| 381 | if err := rows.Close(); err != nil { |
| 382 | return nil, err |
| 383 | } |
| 384 | if err := rows.Err(); err != nil { |
| 385 | return nil, err |
| 386 | } |
| 387 | return items, nil |
| 388 | } |
| 389 | |
| 390 | const selectSpan = `-- name: SelectSpan :one |
| 391 | SELECT |
no test coverage detected