CREATE TABLE FLIGHT
(
ID INT NOT NULL AUTO_INCREMENT,
FLIGHT_NO VARCHAR(20) NOT NULL,
OPERATING_AIRLINES VARCHAR(20) NOT NULL,
DEPARTURE_CITY VARCHAR(20) NOT NULL,
ARRIVAL_CITY VARCHAR(20) NOT NULL,
DATE_OF_DEPARTURE DATE NOT NULL,
ESTIMATED_DEPARTURE_TIME TIMESTAMP DEFAULT CURRENT_TIMESTAMP ,
PRIMARY KEY(ID)
)
when i do:
insert into flight values
(1,'AA1','American Airlines','AUS','NYC', STR_TO_DATE('02-05-2018','%m-%d-%y'), '2018-02-05 03:14:07')
getting this error:
Error Code: 1292. Truncated incorrect date value: '02-05-2018' 0.000 sec
question from:
https://stackoverflow.com/questions/65913610/in-my-situation-error-inserting-a-record-into-database-table-using-mysql-workbe 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…