Blog Sections Open
Fixing AjaxSearch TV Queries That Reference Unknown Columns
TV-based search works only when the query builder and the actual SQL aliases agree on what the TV field is called.
The donor contained a full SQL error from AjaxSearch:
Unknown column 'tv_tv_serchkeyw' in 'having clause'
The listing used:
[!AjaxSearch?
&ajaxSearch=`0`
&showInputForm=`0`
&grabMax=`10`
&pagingType=`0`
&parents=`in:3`
&whereSearch=`content:pagetitle|tv:tv_serchkeyw`
!]
What went wrong
The search configuration referenced a TV alias that the generated SQL did not actually expose under that name. This is a common failure mode when TV-aware search helpers build grouped queries and HAVING clauses automatically.
How to debug it
- inspect the generated SQL, not only the snippet call
- confirm the exact alias names available in the query
- check whether the TV is joined, grouped, or flattened the way the search helper expects
The lesson is simple: once TV search gets advanced enough to generate custom SQL, the debugging target is the SQL layer, not just the snippet parameters.
Fixing TinyMCE Output That Adds Empty Paragraphs Around Lists
Why TinyMCE can produce extra empty paragraphs around lists and nested structures, and how to approach cleanup without breaking intentional markup.
Investigating WSO Web Shell Indicators in a MODX Project
A practical incident-oriented note on spotting suspicious connector activity and WSO web shell indicators in a compromised MODX project.