MySQL Forums
Forum List  »  PHP

Re: Unexpected Data truncated for Date
Posted by: Peter Brawley
Date: June 12, 2019 03:17PM

Arggh, d_calcdate and d_birthdate are INTs.

drop table if exists t;
create table t(d int);
insert into t values(1872-12-13),('1872-12-13');
Warning (Code 1265): Data truncated for column 'd' at row 1
select * from t;
+------+
| d    |
+------+
| 1847 |
| 1872 |
+------+

Store dates in DATE columns.

Options: ReplyQuote


Subject
Written By
Posted
Re: Unexpected Data truncated for Date
June 12, 2019 03:17PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.