You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-01 06:46:55 +03:00
MCOL-4674 Fix ColumnStore to run MTR tests in a build directory
This commit is contained in:
@ -0,0 +1,5 @@
|
||||
[myisam]
|
||||
default_storage_engine=myisam
|
||||
|
||||
[columnstore]
|
||||
default_storage_engine=columnstore
|
@ -0,0 +1,20 @@
|
||||
# This file is needed to force tests use combinations.myisam-columnstore.combinations
|
||||
# Also, let's set default_storage_engine:
|
||||
# - either according to the current combination
|
||||
# - or to ColumnStore by default, if mtr is running
|
||||
# without combinations (e.g with --extern)
|
||||
|
||||
|
||||
--disable_query_log
|
||||
SET @combination=NULL;
|
||||
if ($MTR_COMBINATION_MYISAM)
|
||||
{
|
||||
SET @combination="MYISAM";
|
||||
}
|
||||
if ($MTR_COMBINATION_COLUMNSTORE)
|
||||
{
|
||||
SET @combination="COLUMNSTORE";
|
||||
}
|
||||
|
||||
SET @@default_storage_engine=COALESCE(@combination,'ColumnStore');
|
||||
--enable_query_log
|
10
mysql-test/columnstore/include/have_columnstore.inc
Normal file
10
mysql-test/columnstore/include/have_columnstore.inc
Normal file
@ -0,0 +1,10 @@
|
||||
let $notcolumnstore = `SELECT COUNT(*) = 0 FROM INFORMATION_SCHEMA.ENGINES WHERE engine = 'columnstore' AND support IN ('YES', 'DEFAULT', 'ENABLED')`;
|
||||
|
||||
if ($notcolumnstore == 1)
|
||||
{
|
||||
--skip Test requires engine ColumnStore.
|
||||
}
|
||||
|
||||
--disable_query_log
|
||||
set global character_set_server='latin1';
|
||||
--enable_query_log
|
@ -0,0 +1,28 @@
|
||||
# set the count of collations in a variable for a character set
|
||||
let $col_count = `SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLLATIONS WHERE CHARACTER_SET_NAME LIKE '$char_set'`;
|
||||
|
||||
#create table with all supported collations for a character set
|
||||
if(!$column_flag)
|
||||
{
|
||||
while($col_count)
|
||||
{
|
||||
let $i = `SELECT $col_count-1`;
|
||||
let $collation = `SELECT COLLATION_NAME FROM INFORMATION_SCHEMA.COLLATIONS WHERE CHARACTER_SET_NAME LIKE '$char_set' LIMIT $i,1`;
|
||||
eval CREATE TABLE t_$col_count$char_set(name VARCHAR(10)) CHARSET $char_set COLLATE '$collation' ENGINE=Columnstore;
|
||||
eval SHOW CREATE TABLE t_$col_count$char_set;
|
||||
dec $col_count;
|
||||
}
|
||||
}
|
||||
|
||||
#create table with all supported collations for a character set at column level
|
||||
if($column_flag)
|
||||
{
|
||||
while($col_count)
|
||||
{
|
||||
let $i = `SELECT $col_count-1`;
|
||||
let $collation = `SELECT COLLATION_NAME FROM INFORMATION_SCHEMA.COLLATIONS WHERE CHARACTER_SET_NAME LIKE '$char_set' LIMIT $i,1`;
|
||||
eval CREATE TABLE tcol_$col_count$char_set (name CHAR(3) CHARACTER SET $char_set COLLATE '$collation') ENGINE=Columnstore;
|
||||
eval SHOW CREATE TABLE tcol_$col_count$char_set;
|
||||
dec $col_count;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user