ExamVeda
Login
Home
This question belongs to MySQL MySQL Miscellaneous
MySQL Miscellaneous
?

Which data and time datatype stores time value in 'hh:mm:ss' format?

Answer & Solution
Correct Answer: Option B
This question asks about storing time values in a specific format: 'hh:mm:ss'. Let's break down the options:
Option A: DATE
This data type is used to store dates in the format 'YYYY-MM-DD'. It does not store time information.
Option B: TIME
This is the correct answer! TIME is specifically designed to store time values in the format 'hh:mm:ss' (hours, minutes, seconds).
Option C: DATETIME
This data type stores both date and time information, typically in the format 'YYYY-MM-DD hh:mm:ss'. While it can hold a time value, it's not the most efficient choice for storing just the time.
Option D: TIMESTAMP
This data type is used to store timestamps, which are combinations of a date and time. It's often used for tracking when data was created or modified.
Therefore, the answer is Option B: TIME.
Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.