Problem: Error while preparing query
SELECT s.ID,s.title AS sermon_title, mp.city, m.city AS secCity, m.meeting_start, m.no_date, mp.title,
s.meeting_id, c.title AS country, s.url, s.language, s.preached_at,
GROUP_CONCAT(s.file_name) AS file_name, GROUP_CONCAT(s.embed_code) AS embed_code,
c.ext AS country_mark, s.author_id, s.book_id, meeting_place_id, m.scriptures_text, m.scriptures_references,
b.url AS bUrl,b.language AS bLanguage, b.epub AS bEpub, b.pdf AS bPdf, b.ibook AS bIbook,
IF(s.meeting_id = 0, s.preached_at, m.meeting_start) AS orderColumn, s.description
FROM msk_sermons AS s
LEFT JOIN msk_meetings AS m
ON s.meeting_id = m.ID
LEFT JOIN msk_meeting_places AS mp
ON mp.ID = m.meeting_place_id
LEFT JOIN msk_countries AS c
ON mp.country_id = c.ID
LEFT JOIN msk_books AS b
ON s.meeting_id = b.meeting_id and b.language = s.language
WHERE s.production = 1
AND s.mainswitch = 1 AND m.meeting_place_id = AND m.meeting_start < "N/A" GROUP BY s.language, s.meeting_id, s.preached_at
ORDER BY orderColumn DESC
LIMIT 1000
Type of error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND m.meeting_start < "N/A" GROUP BY s.language, s.meeting_id, s.preached_at
' at line 17