I did my reading on this and still can’t make sense why my query doesn’t work. It’s a rather simple INNER JOIN and we’re working on MySQL5. I know, there was a change with join with the precedence of explicitly called joins over comas. But I’m not doing any of that.
My assembled query looks like this:
SELECT SQL_CALC_FOUND_ROWS k_services.id, service_status, service_tourno, service_date, service_cxlDate, service_difficultPeriod, service_priority, service_currency, service_key_so, service_price_so, service_key_ok, service_price_cfm, service_supplement
FROM k_services
JOIN k_remarks ON k_remarks.remark_service = k_services.id
WHERE k_services.service_market = 2 AND k_remarks.remark_type = 9
LIMIT 0, 25
Which returns me an error:
Unknown column ‘k_remarks.remark_type’ in ‘where clause.
However, when I pop this exact same query into SQLyog it executes just fine with the desired/expected results.
Try: