Blog Sections Open

Why a Simple @SELECT TV Binding Can Trigger a 500 Error

A migration troubleshooting note for cases where a previously normal @SELECT TV suddenly starts failing after a hosting move.

One of the most frustrating migration bugs is when an ordinary TV definition works on one host and throws a 500 error on another, with no useful message in the error log.

The donor case

@SELECT `pagetitle` AS `name`,`id`
FROM `[[+PREFIX]]site_content`
WHERE `deleted` = 0 AND `published` = 1
ORDER BY `name` ASC

After a hosting move, opening the resource form for a template using that TV immediately returned a 500 error.

What to investigate

  • SQL mode differences between hosts
  • prefix substitution issues
  • database permissions or charset mismatches
  • PHP or database extensions behaving differently on the new host
Newer post

Understanding OnWebPagePrerender and Cached Output

A cache-debugging note for developers who expect OnWebPagePrerender changes to be frozen in the page cache but see output still changing on every request.

Older post

When Strict URLs Becomes a Performance Bottleneck

A performance cautionary note for large catalogs where URL normalization plugins can become unexpectedly expensive during page generation.