how to assign date field for table in mysql
snippet in sql

mysql format date

user7336

DATE_FORMAT(date, format)
-- E.g.
SELECT DATE_FORMAT(dateField, '%m/%d/%Y') FROM TableName;
-- See https://www.mysqltutorial.org/mysql-date_format/ for available formats

how to assign date field for table in mysql

user1646


        
            
        
     CREATE TABLE people (
    id INT AUTO_INCREMENT PRIMARY KEY,
    first_name VARCHAR(50) NOT NULL,
    last_name VARCHAR(50) NOT NULL,
    birth_date DATE NOT NULL
);