does worker use TCP for D1 or HTTP? like does it count as an outgoing request?
does worker use TCP for D1 or HTTP? like does it count as an outgoing request?
2/17/24, 7:42 PM
p.posted and p.retry but it's still scanning the whole table p. Is there anyway to reduce scanned rows of the query above? I'm running this query every minutes so everyday I'm wasting 10-20k scanned row. This table is going to grow much larger so the waste will be more significant
posted and retry, or two individual indexes?posted and retry if I place the condition in the correct order right?posted and retry should be used
SELECT *
FROM categories
JOIN images_categories ON categories.id = images_categories.category_id
JOIN images ON images_categories.image_id = images.id; let result = await platform!.env.DB.prepare(
`SELECT *
FROM categories
JOIN images_categories ON categories.id = images_categories.category_id
JOIN images ON images_categories.image_id = images.id;
`
).all();CREATE INDEX post_posted_retry_idx ON post (posted, retry);Error: D1_ERROR: FOREIGN KEY constraint failed
at D1Database._sendOrThrow (cloudflare-internal:d1-api:66:19)