0

我试图通过每 24 小时仅插入唯一值来跟踪页面浏览量。但是当我运行此查询时,出现语法错误。

insert ignore into profilepageviews values( '77.777.777.777' , CURRENT_TIMESTAMP, '5') where hitdate NOT LIKE '%2012-06-26%'

错误:

#1064 - 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 'where hitdate NOT LIKE '%2012-06-26%'' at line 1
4

1 回答 1

3

您不能将WHERE子句与 一起使用INSERT,您可能想要UPDATE

于 2012-06-26T11:54:36.707 回答