MYSQL ERROR
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 '(_name like '%ปลัดกรุงเทพมหานคร%') OR ) AND _s' at line 49
Query :: SELECT
          _id AS s_id,
          _mid AS s_mid,
          _mkey AS s_mkey,
          _subject AS s_subject,
          _desc AS s_desc,
      		_count AS s_count,
      		_dtmins AS s_dtmins,
      		null AS s_typenews,
      		null AS s_link,
          null AS s_name,
          _tag AS s_tag
           FROM cms WHERE 1=1 AND _mid IN(81,80,79,78,77,76,75,83,84,92,91,116,122,115,120,113,119,112,121,118,58,48,47,46,38,146,54,181,164,165,163,31,185,16,167,1,171,21,55,170,22,168,87,169,45,156,176,52,97,98,133,153,175,37,99,159,44,96,154,41,49,95,40,94,179,39,109,147,43,93,162,180,90,100,144,178,36,51,143,184,35,50,73,142,161,183,33,34,132,141,145,182,88,127,166,186) AND (_subject = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR _desc = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR _tag = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร') AND _status = 'Enable' AND _lang = 'th' UNION SELECT
        _id AS s_id,
        _mid AS s_mid,
        _mkey AS s_mkey,
        _subject AS s_subject,
        _desc AS s_desc,
    		_count AS s_count,
    		_dtmins AS s_dtmins,
    		null AS s_typenews,
    		null AS s_link,
        null AS s_name,
        _tag AS s_tag
        FROM media WHERE 1=1 AND _mid IN(81,80,79,78,77,76,75,83,84,92,91,116,122,115,120,113,119,112,121,118,58,48,47,46,38,146,54,181,164,165,163,31,185,16,167,1,171,21,55,170,22,168,87,169,45,156,176,52,97,98,133,153,175,37,99,159,44,96,154,41,49,95,40,94,179,39,109,147,43,93,162,180,90,100,144,178,36,51,143,184,35,50,73,142,161,183,33,34,132,141,145,182,88,127,166,186) AND (_subject = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR _desc = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR _tag = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร') AND _status = 'Enable' AND _lang = 'th' UNION SELECT
        _id AS s_id,
        _mid AS s_mid,
        _mkey AS s_mkey,
        _subject AS s_subject,
        _desc AS s_desc,
        _count AS s_count,
        _dtmins AS s_dtmins,
        null AS s_typenews,
        null AS s_link,
        null AS s_name,
        null AS s_tag
        FROM rss WHERE 1=1 AND _mid IN(81,80,79,78,77,76,75,83,84,92,91,116,122,115,120,113,119,112,121,118,58,48,47,46,38,146,54,181,164,165,163,31,185,16,167,1,171,21,55,170,22,168,87,169,45,156,176,52,97,98,133,153,175,37,99,159,44,96,154,41,49,95,40,94,179,39,109,147,43,93,162,180,90,100,144,178,36,51,143,184,35,50,73,142,161,183,33,34,132,141,145,182,88,127,166,186) AND (_subject = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR _desc = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร') AND _status = 'Enable' AND _lang = 'th' UNION SELECT
          _id AS s_id,
          _mid AS s_mid,
          _mkey AS s_mkey,
          _name AS s_subject,
          _desc AS s_desc,
          _count AS s_count,
          _dtmins AS s_dtmins,
          null AS s_typenews,
          null AS s_link,
          _name AS s_name,
          null As s_tag
          FROM document WHERE 1=1 AND _mid IN(81,80,79,78,77,76,75,83,84,92,91,116,122,115,120,113,119,112,121,118,58,48,47,46,38,146,54,181,164,165,163,31,185,16,167,1,171,21,55,170,22,168,87,169,45,156,176,52,97,98,133,153,175,37,99,159,44,96,154,41,49,95,40,94,179,39,109,147,43,93,162,180,90,100,144,178,36,51,143,184,35,50,73,142,161,183,33,34,132,141,145,182,88,127,166,186) AND _did = 0 AND ( (_name like '%นางศิลปสวย%') OR  (_name like '%ระวีแสงสูรย์%') (_name like '%ปลัดกรุงเทพมหานคร%') OR ) AND _status = 'Enable' AND _lang = 'th' UNION SELECT
    page._id AS s_id,
    page._mid AS s_mid,
    page._mkey AS s_mkey,
    sys_menu._name_th AS s_subject,
    null AS s_desc,
    page._count_th AS s_count,
    page._dtmins AS s_dtmins,
    null AS s_typenews,
    sys_menu._urlname AS s_link,
    null AS s_name,
    page._tag_th AS s_tag
     FROM page INNER JOIN sys_menu ON sys_menu._id = page._mid  WHERE 1=1 AND page._mid IN(81,80,79,78,77,76,75,83,84,92,91,116,122,115,120,113,119,112,121,118,58,48,47,46,38,146,54,181,164,165,163,31,185,16,167,1,171,21,55,170,22,168,87,169,45,156,176,52,97,98,133,153,175,37,99,159,44,96,154,41,49,95,40,94,179,39,109,147,43,93,162,180,90,100,144,178,36,51,143,184,35,50,73,142,161,183,33,34,132,141,145,182,88,127,166,186) AND (sys_menu._name_th = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR sys_menu._desc_th = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR page._tag_th = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร') AND sys_menu._status = 'Enable' UNION SELECT
          _id AS s_id,
          _mid AS s_mid,
          _mkey AS s_mkey,
          _subject AS s_subject,
          _desc AS s_desc,
          _count AS s_count,
          _dtmins AS s_dtmins,
          null AS s_typenews,
          null AS s_link,
          null AS s_name,
          _tag As s_tag
          FROM album WHERE 1=1 AND _mid IN(81,80,79,78,77,76,75,83,84,92,91,116,122,115,120,113,119,112,121,118,58,48,47,46,38,146,54,181,164,165,163,31,185,16,167,1,171,21,55,170,22,168,87,169,45,156,176,52,97,98,133,153,175,37,99,159,44,96,154,41,49,95,40,94,179,39,109,147,43,93,162,180,90,100,144,178,36,51,143,184,35,50,73,142,161,183,33,34,132,141,145,182,88,127,166,186) AND (_subject = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR _desc = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร' OR _tag = 'นางศิลปสวย ระวีแสงสูรย์ ปลัดกรุงเทพมหานคร') AND _status = 'Enable' AND _lang = 'th'ORDER BY s_dtmins DESC