(placeholderValues?: Record<string, unknown>)
| 197 | } |
| 198 | |
| 199 | async run(placeholderValues?: Record<string, unknown>): Promise<D1Response> { |
| 200 | const params = fillPlaceholders(this.query.params, placeholderValues ?? {}); |
| 201 | this.logger.logQuery(this.query.sql, params); |
| 202 | return await this.queryWithCache(this.query.sql, params, async () => { |
| 203 | return this.stmt.bind(...params).run(); |
| 204 | }); |
| 205 | } |
| 206 | |
| 207 | async all(placeholderValues?: Record<string, unknown>): Promise<T['all']> { |
| 208 | const { fields, query, logger, stmt, customResultMapper } = this; |