Есть такой вот простой запрос:
который myAdmin выполняет на ура. Однако самый обычный CDatabase::Query выдает следующую ошибку:
Query Error: CREATE TEMPORARY TABLE `tt_dates` (`date` date, `weekday` int, `timeStart` time, `timeEnd` time); INS ERT IN TO `tt_dates` VALUES ('2016-05-03',2,'18:30:00','23:59:59'); INS ERT IN TO `tt_dates` VALUES ('2016-05-04',3,'00:00:00','16:00:00'); SELE CT * FR OM `tt_dates` [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 'INS ERT IN TO `tt_dates` VALUES ('2016-05-03',2,'18:30:00','23:59:59'); ' at line 2!]
В чем может быть проблема?
Код |
---|
CREATE TEMPORARY TABLE `tt_dates` (`date` date, `weekday` int, `timeStart` time, `timeEnd` time); INS ERT INTO `tt_dates` VALUES ('2016-05-03',2,'18:30:00','23:59:59'); INS ERT IN TO `tt_dates` VALUES ('2016-05-04',3,'00:00:00','16:00:00'); SEL ECT * FROM `tt_dates` |
Query Error: CREATE TEMPORARY TABLE `tt_dates` (`date` date, `weekday` int, `timeStart` time, `timeEnd` time); INS ERT IN TO `tt_dates` VALUES ('2016-05-03',2,'18:30:00','23:59:59'); INS ERT IN TO `tt_dates` VALUES ('2016-05-04',3,'00:00:00','16:00:00'); SELE CT * FR OM `tt_dates` [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 'INS ERT IN TO `tt_dates` VALUES ('2016-05-03',2,'18:30:00','23:59:59'); ' at line 2!]
В чем может быть проблема?