mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-04-21 19:45:56 +03:00
29 lines
734 B
Plaintext
29 lines
734 B
Plaintext
# -------------------------------------------------------------- #
|
|
# Test case migrated from regression test suite: bug4346.sql
|
|
#
|
|
# Author: Daniel Lee, daniel.lee@mariadb.com
|
|
# -------------------------------------------------------------- #
|
|
#
|
|
--source ../include/have_columnstore.inc
|
|
#
|
|
USE tpch1;
|
|
#
|
|
--disable_warnings
|
|
drop table if exists dim_day;
|
|
--enable_warnings
|
|
|
|
CREATE TABLE `dim_day` (
|
|
`dayId` SMALLINT(5) DEFAULT NULL,
|
|
`displayDate` DATE DEFAULT NULL
|
|
) engine=columnstore DEFAULT CHARSET=utf8;
|
|
INSERT INTO dim_day (dayId, displayDate) VALUES (1,'2012-01-01') ,
|
|
(2,'2012-02-01');
|
|
SELECT STR_TO_DATE(CONCAT(YEARWEEK(displayDate,2),'-01'),'%X%V-%w')
|
|
FROM dim_day;
|
|
|
|
--disable_warnings
|
|
drop table dim_day;
|
|
--enable_warnings
|
|
#
|
|
|