mirror of
https://github.com/MariaDB/server.git
synced 2025-08-07 00:04:31 +03:00
Added a test case for bug #20293 "group by cuts off value from time_format"
This commit is contained in:
@@ -1207,3 +1207,7 @@ SET NAMES DEFAULT;
|
|||||||
select str_to_date('10:00 PM', '%h:%i %p') + INTERVAL 10 MINUTE;
|
select str_to_date('10:00 PM', '%h:%i %p') + INTERVAL 10 MINUTE;
|
||||||
str_to_date('10:00 PM', '%h:%i %p') + INTERVAL 10 MINUTE
|
str_to_date('10:00 PM', '%h:%i %p') + INTERVAL 10 MINUTE
|
||||||
NULL
|
NULL
|
||||||
|
SELECT TIME_FORMAT(SEC_TO_TIME(a),"%H:%i:%s") FROM (SELECT 3020399 AS a UNION SELECT 3020398 ) x GROUP BY 1;
|
||||||
|
TIME_FORMAT(SEC_TO_TIME(a),"%H:%i:%s")
|
||||||
|
838:59:58
|
||||||
|
838:59:59
|
||||||
|
@@ -713,3 +713,11 @@ SET NAMES DEFAULT;
|
|||||||
#
|
#
|
||||||
|
|
||||||
select str_to_date('10:00 PM', '%h:%i %p') + INTERVAL 10 MINUTE;
|
select str_to_date('10:00 PM', '%h:%i %p') + INTERVAL 10 MINUTE;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Bug #20293: group by cuts off value from time_format
|
||||||
|
#
|
||||||
|
# Check if using GROUP BY with TIME_FORMAT() produces correct results
|
||||||
|
|
||||||
|
SELECT TIME_FORMAT(SEC_TO_TIME(a),"%H:%i:%s") FROM (SELECT 3020399 AS a UNION SELECT 3020398 ) x GROUP BY 1;
|
||||||
|
Reference in New Issue
Block a user