I need to save the current time and date separately when the query is executed automatically but I am not sure how I can do this and if it is the correct way I do it.
CREATE TABLE 'prestamo_equipos'.'prestamo_usuarios' (
'alumno_matricula' INT NOT NULL,
'id_equipo' VARCHAR(45) NOT NULL,
'fecha' DATE NOT NULL DEFAULT CURDATE(),
'hora' DATE NOT NULL DEFAULT CURTIME(),
PRIMARY KEY ('alumno_matricula', 'id_equipo'));