SqlExecutor
type SqlExecutor = <T>(strings, ...values) => T[];SQL executor type matching Cloudflare’s Durable Object sql binding.
Returns rows directly as an array — NOT an object with .toArray(). This
was a long-standing type bug that surfaced today when the voice path
started routing through OrchestrationStore.get(): SQL returned an array
but code called .toArray() on it, throwing TypeError.
Verified against the cloudflare/agents base class at
packages/agents/src/index.ts:881-888 — const result = this.sql...
followed by result.length/result[0] with no .toArray() anywhere.
Type Parameters
Section titled “Type Parameters”| Type Parameter | Default type |
|---|---|
|
|
|
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
|
|
|
|
… |
|
Returns
Section titled “Returns”T[]