when I run this sql
select date from hrm where month(date)=month(curdate())
it’s ok,but when i run this sql
insert into A(date) select date from hrm where month(date)=month(curdate())
there have Invalid datetime value ” problem,
i fix it by change my sql to this
insert into A(date) select date from hrm where id not in (select id from hrm where date<>'') and month(date)=month(curdate())
I want to know why insert into have this problem, and any website can be reference?
1