So definitely whitespace-related. Just super-hard to determine from the error message.
So definitely whitespace-related. Just super-hard to determine from the error message.
[ERROR] Error: D1_ERROR that's happening on production but not locally?INSERT INTO calendar (c_id, for_date, status) VALUES (?1, ?2, ?3) ON CONFLICT DO UPDATE SET status = excluded.status;'INSERT INTO calendar (c_id, for_date, status) VALUES ('122393', '2023-04-03', 'AVAILABLE') ON CONFLICT DO UPDATE SET status = excluded.status;
[ERROR] Error: D1_ERROR (error) Error: Error: Error 9000: exception caught in D1 core. unreachable RuntimeError: unreachable
at wasm://wasm/00f5753e:wasm-function[4783]:0x31be54
at wasm://wasm/00f5753e:wasm-function[4836]:0x322be4
at wasm://wasm/00f5753e:wasm-function[4877]:0x32c7d6
at wasm://wasm/00f5753e:wasm-function[237]:0x29575
at wasm://wasm/00f5753e:wasm-function[4973]:0x34351d
at Object.s2 [as query] (index.js:2418:157)
at async Sqlite.query (index.js:3205:23)
at async sqliteQuery (index.js:9409:29)
at async index.js:9167:22INSERT INTO calendar (c_id, for_date, status) VALUES (?1, ?2, ?3) ON CONFLICT DO UPDATE SET status = excluded.status;'INSERT INTO calendar (c_id, for_date, status) VALUES ('122393', '2023-04-03', 'AVAILABLE') ON CONFLICT DO UPDATE SET status = excluded.status;INSERT INTO calendar (c_id, for_date, status)
VALUES
(122393 '2023-04-03', 'AVAILABLE'),
(122393 '2023-04-04', 'AVAILABLE'),
(122393, '2023-04-05', 'AVAILABLE'),
...
ON CONFLICT DO UPDATE SET status = excluded.status;