If you’re looking for help, please provide information about your environment. If you delete this template and don’t provide any information, your topic will be automatically closed.
If you aren’t running the latest version of Ghost, the first thing we’ll ask you to do is update to the latest version of Ghost.
- What’s your URL? https://cocktaildetour.com
- What version of Ghost are you using? Latest
How was Ghost installed and configured? It was installed via the terminal with cli tool
What Node version, database, OS & browser are you using? nodejs version 18.12.1 using MariaDB 10.6.11 using latest firefox at MacOS
What errors or information do you see in the console? When trying to view statistics of a post, 400 error happens. It seemed to work fine before update to Ghost 5.
"id":"ed9ca9e0-add5-11ed-aa01-6f1cfec52e42", "domain":"https://cocktaildetour.com", "code":"ER_BAD_FIELD_ERROR", "name":"BadRequestError", "statusCode":400, "level":"normal", "message":"Could not understand request.", "stack":"Error: select `posts`.*, (with `k` as (select `member_id` from `members_subscription_created_events` where posts.id = members_subscription_created_events.attribution_id union select `member_id` from `members_created_events` where posts.id = members_created_events.attribution_id) select count(*) from `k`) as `count__conversions`, `posts`.*, (select count(distinct `members_click_events`.`member_id`) from `members_click_events` inner join `redirects` on `members_click_events`.`redirect_id` = `redirects`.`id` where posts.id = redirects.post_id) as `count__clicks`, `posts`.*, (select COALESCE(ROUND(AVG(score) * 100), 0) from `members_feedback` where posts.id = members_feedback.post_id) as `count__sentiment`, `posts`.*, (select count(*) from `members_feedback` where posts.id = members_feedback.post_id AND members_feedback.score = 0) as `count__negative_feedback`, `posts`.*, (select sum(`score`) from `members_feedback` where posts.id = members_feedback.post_id) as `count__positive_feedback` from `posts` where (`posts`.`type` = 'post' and `posts`.`status` in ('draft', 'published', 'scheduled', 'sent')) and `posts`.`id` = '63e778e42ce6c5f177c33d15' limit 1 - Unknown column 'posts.id' in 'where clause'\n at Child.<anonymous> (/var/www/cocktaildetour.com/versions/5.34.0/core/server/models/base/plugins/crud.js:175:31)\n at Packet.asError (/var/www/cocktaildetour.com/versions/5.34.0/node_modules/mysql2/lib/packets/packet.js:728:17)\n at Query.execute (/var/www/cocktaildetour.com/versions/5.34.0/node_modules/mysql2/lib/commands/command.js:29:26)\n at Connection.handlePacket (/var/www/cocktaildetour.com/versions/5.34.0/node_modules/mysql2/lib/connection.js:488:32)\n at PacketParser.onPacket (/var/www/cocktaildetour.com/versions/5.34.0/node_modules/mysql2/lib/connection.js:94:12)\n at PacketParser.executeStart (/var/www/cocktaildetour.com/versions/5.34.0/node_modules/mysql2/lib/packet_parser.js:75:16)\n at Socket.<anonymous> (/var/www/cocktaildetour.com/versions/5.34.0/node_modules/mysql2/lib/connection.js:101:25)\n at Socket.emit (events.js:376:20)\n at addChunk (internal/streams/readable.js:309:12)\n at readableAddChunk (internal/streams/readable.js:284:9)\n at Socket.Readable.push (internal/streams/readable.js:223:10)\n at TCP.onStreamRead (internal/stream_base_commons.js:188:23)", "hideStack":false
What steps could someone else take to reproduce the issue you’re having? They could view analytics in the posts