Overview
Concepts
Cluster Architecture
Strengths
Scenarios
"in_memory"="true" in PROPERTIES during table creation, such as:CREATE TABLE IF NOT EXISTS example_db.expamle_tbl(`user_id` LARGEINT NOT NULL COMMENT "user id",`date` DATE NOT NULL COMMENT "data import date",`city` VARCHAR(20) COMMENT "user's city",`age` SMALLINT COMMENT "user's age",`sex` TINYINT COMMENT "user's gender",`last_visit_date` DATETIME REPLACE DEFAULT "1970-01-01 00:00:00" COMMENT "last visit time of user",`cost` BIGINT SUM DEFAULT "0" COMMENT "total consumption of user",`max_dwell_time` INT MAX DEFAULT "0" COMMENT "user's maximum stay time",`min_dwell_time` INT MIN DEFAULT "99999" COMMENT "user's minimum stay time")AGGREGATE KEY(`user_id`, `date`, `city`, `age`, `sex`)DISTRIBUTED BY HASH(`user_id`) BUCKETS 1PROPERTIES ("replication_allocation" = "tag.location.default: 1","in_memory"="true");
"in_memory"="true":ALTER TABLE example_db.my_table set ("in_memory" = "true");
"in_memory"="true" when creating the partition:ALTER TABLE example_db.my_table ADD [TEMPORARY] PARTITION p1 VALUES LESS THAN ("2020-02-01") ("in_memory" = "true", "replication_num" = "1")
"in_memory"="true":ALTER TABLE example_db.my_table MODIFY PARTITION (p1, p2, p4) SET("in_memory"="true");
"in_memory"="false".ALTER TABLE example_db.my_table set ("in_memory" = "false");
ALTER TABLE example_db.my_table MODIFY PARTITION (p1, p2, p4) SET("in_memory"="false");
"in_memory" = "true" attribute, Doris will try to cache the data blocks of the table in the storage engine's PageCache to reduce disk IO. However, this attribute does not guarantee that the data blocks will always reside in memory, and it is merely a best-effort indicator.

[root@9 data]# tail test.sqlselect * from supplier where s_suppkey=1;...select * from supplier where s_suppkey=999991;select * from supplier where s_suppkey=999992;select * from supplier where s_suppkey=999993;select * from supplier where s_suppkey=999994;select * from supplier where s_suppkey=999995;select * from supplier where s_suppkey=999996;select * from supplier where s_suppkey=999997;select * from supplier where s_suppkey=999998;select * from supplier where s_suppkey=999999;[root@9 data]# tail test2.sqlselect * from supplier1 where s_suppkey=1;...select * from supplier1 where s_suppkey=999991;select * from supplier1 where s_suppkey=999992;select * from supplier1 where s_suppkey=999993;select * from supplier1 where s_suppkey=999994;select * from supplier1 where s_suppkey=999995;select * from supplier1 where s_suppkey=999996;select * from supplier1 where s_suppkey=999997;select * from supplier1 where s_suppkey=999998;select * from supplier1 where s_suppkey=999999;
mysqlslap -h127.0.0.1 -uadmin -P9030 -pxxxxx --iterations=1 --concurrency=500 --number-of-queries=1000000 --create-schema=tpch_100_d --query="/data/test1.sql" --delimiter=";";


Esta página foi útil?
Você também pode entrar em contato com a Equipe de vendas ou Enviar um tíquete em caso de ajuda.
comentários