putyourlightson / craft-blitz

Intelligent static page caching for creating lightning-fast sites with Craft CMS.

Home Page:https://putyourlightson.com/plugins/blitz

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SQLSTATE[HY000]: General error: 7 number of parameters must be between 0 and 65535

boboldehampsink opened this issue · comments

Bug Report

Seeing this come up in various variants:

SQLSTATE[HY000]: General error: 7 number of parameters must be between 0 and 65535 The SQL being executed was: SELECT "id" FROM "blitz_caches" WHERE (("siteId"=1) AND ("uri"='...')) OR (("siteId"=1) AND ("uri"='......

I'm on PostgreSQL

Plugin Version

4.13

Craft CMS Version

4.8

PHP Version

8.3

Are you seeing a stack trace along with these errors, or can you track one down in the logs?

Ah, forgot to mention this is shown as a "Refreshing Blitz Cache" job error (no full stacktrace comes with that)

Thanks! Fixed in 2440fd8 for the next release.

Thanks! When is the release planned? My queue manager is actually crashing now a few of these big ones have shown up - have to delete them manually from the db to make things work again.

Early next week. If you need this sooner then you can install the develop branch by running ddev composer require "putyourlightson/craft-blitz:dev-develop as 4.13.3".

@bencroker now seeing this slightly different message (using develop):

SQLSTATE[HY000]: General error: 7 number of parameters must be between 0 and 65535 The SQL being executed was: SELECT "siteId", "uri" FROM "blitz_caches" WHERE "id" IN (205807, 205908, 182419, ...

Thanks. I’ve added chunking of query params in more places in 4c0edf6. Hopefully that catches them all now.

Released in 4.14.0.