An exception occurred in shop's script

  • Error type: MySQL Error
  • Source, line: Parser::tws_shop_topic[1289]
  • Error message: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'id IN(2420,2994,2995,2996,2998,3006,3012,3013,3014,3016,3017,3019,3020,3021,4925' at line 23
 SELECT DISTINCT id
                        FROM (
                            SELECT s.id
                            FROM ms_store s, ms_topic_store ts
                            WHERE s.no_visible=0
                                AND s.kind_key = 'kDefault'
                                AND s.price2 > s.price
                                AND s.price > 0
                                AND ts.store_id = s.id
                            UNION ALL
                            SELECT s.id
                            FROM ms_store s
                                JOIN ms_topic_store ts ON s.id = ts.store_id   
                                JOIN ms_disc_group dg ON s.disc_group_id = dg.id  
                                JOIN ms_disc_rate dr ON dr.group_id = dg.id
                            WHERE dr.kind_key = 'kOrder'
                                AND dr.from_sum = 0
                                AND dr.begin_time < '2024-03-29 13:03:58'
                                AND dr.end_time > '2024-03-29 13:03:58'
                                AND (s.price - (s.price / 100 * dr.disc_proc)) < s.price
                                AND s.no_visible = 0
                                AND s.kind_key = 'kDefault' 
                        ) AS tblWHERE id IN(2420,2994,2995,2996,2998,3006,3012,3013,3014,3016,3017,3019,3020,3021,4925,10410,10412,10413,17440,23559,23560,30774,30775,30776,30777,30778,31151,31152,31211,31212,31213,54008,54009,58301,58302,58303,58304,58305,58306,58523,58525,58527,61673,61674,63612,64015,64016,64017,65676,65677)