-
Notifications
You must be signed in to change notification settings - Fork 6
Practices
Shannon Data AI Lab edited this page Apr 17, 2024
·
10 revisions
The practice cases of ShannonBase.
the script of creating table and loading data can be found here. https://github.com/Shannon-Data/heatwave-tpch/tree/main/TPCH.
After we have loaded the data into rapid engine, then, start to run queries.
Taking NATION
as an instance.
create database tpch_1024;
alter database tpch_1024 CHARACTER SET ascii COLLATE ascii_bin;
use tpch_1024;
CREATE TABLE NATION ( N_NATIONKEY INTEGER NOT NULL,
N_NAME CHAR(25) NOT NULL,
N_REGIONKEY INTEGER NOT NULL,
N_COMMENT VARCHAR(152),
PRIMARY KEY (N_NATIONKEY));
Load the data into rapid engine.
alter table NATION secondary_load;
and if you want to use rapid
mandatorily.
set use_secondary_engine=forced;
or you can use it according to cost
set secondary_engine_cost_threshold = xxx;
then do query, it will use rapid to do query.
select * from NATION;