The TIME() function extracts the time part from a given time/datetime.
Note: This function returns "00:00:00" if expression is not a datetime/time, or NULL if expression is NULL.
TIME(
expression)
Parameter | Description |
---|---|
expression | Required. The time/datetime to extract the time from |
Works in: | From MySQL 4.0 |
---|
Extract the time part from the datetime expression:
SELECT TIME("2017-08-15 19:30:10");
Try it Yourself »
Extract the time part from the datetime expression:
SELECT TIME("2017-08-15 19:30:10.000001");
Try it Yourself »
截取页面反馈部分,让我们更快修复内容!也可以直接跳过填写反馈内容!