Query failed : SELECT id FROM `accommodation` WHERE (`approved` = 1 AND `town` LIKE '%Beaminster' OR `village` LIKE '%Beaminster') AND `hotels`=1 Unknown column 'hotels' in 'where clause'