当前位置:网站首页>Import the data in MariaDB into columnstore
Import the data in MariaDB into columnstore
2022-07-24 11:34:00 【Yabingshi】
1 stay columnStore Empty meter built in
# View the table definition on the source side
show create table baidd.t1;
CREATE TABLE `t1` (
`id` int(11) NOT NULL,
`name` varchar(30) COLLATE utf8mb4_bin NOT NULL,
`name3` varchar(30) COLLATE utf8mb4_bin DEFAULT NULL,
PRIMARY KEY (`id`,`name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin
# Change the definition in the following table at the target end
# Change the storage engine to columnstore, Remove all indexes ( Include primary key ), Sort character sets and related information .
After the reform :
CREATE TABLE `t1` (
`id` INT(11) NOT NULL,
`name` VARCHAR(30) NOT NULL,
`name3` VARCHAR(30) DEFAULT NULL
) ENGINE=columnstore
2 Leading data
# Export on the source side
select * from baidd.t1 into outfile '/tmp/t1.txt' FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' LINES TERMINATED BY '\n';
# Copy the file to the target side
# stay columnStore Import in
grammar :
cpimport dbName tblName [ Load the file ]
Example :
cpimport baidd t1 /opt/t1.txt -E '"' -s ','
#-E Is the delimiter of the string
#-s Is the end character of the field
After importing, you will be prompted as follows :
2022-04-15 19:37:43 (7959) INFO : For table baidd.t1: 3 rows processed and 3 rows inserted.
2022-04-15 19:37:44 (7959) INFO : Bulk load completed, total run time : 1.08667 seconds
边栏推荐
- JMeter runtime controller
- Shell Scripting tips
- 【反序列化漏洞-02】PHP反序列化漏洞原理测试及魔术方法总结
- Build resume editor based on Nocode
- Text message verification of web crawler
- Sorting out the ideas of data processing received by TCP server, and the note of select: invalid argument error
- MOS管 —— 快速复苏应用笔记(壹)[原理篇]
- Lanqiao cup provincial training camp - stack and recursion
- 2022, the average salary of the soft tester, after reading it, I was instantly cool
- Blue Bridge Cup - binary conversion exercise
猜你喜欢

Reprint of illustrations in nature, issue 3 - area map (part2-100)

Recommended SSH cross platform terminal tool tabby

视频回放 | 如何成为一名优秀的地学和生态学领域的国际期刊审稿人?

【C】 Understanding C language variable scope and life cycle from memory

Cgo+gsoap+onvif learning summary: 9. Go and C conduct socket communication and onvif protocol processing

The third day of hcip mGRE experiment

2022, the average salary of the soft tester, after reading it, I was instantly cool

字符串——344.反转字符串

【C】 Recursive and non recursive writing of binary tree traversal

这才是开发者神器正确的打开方式!
随机推荐
HDU 3351:Seinfeld
How to use SSH and SFTP protocols at home
Hash - 202. Happy number
【Golang】golang实现发送微信服务号模板消息
MicroBlaze adds a custom IP core and attaches the Axi bus to realize ssd1306 OELD drive
哈希——15. 三数之和
Text message verification of web crawler
有关并行的两个重要定律
Win10 icon turns white, recovery method
stream流
The third day of hcip mGRE experiment
2 万字详解,吃透 ES!
【C】 Recursive and non recursive writing of binary tree traversal
Shell Scripting tips
【10】 Teamwork and cross team collaboration
使用Prometheus+Grafana实时监控服务器性能
Hash - 242. valid alphabetic ectopic words
链表——剑指offer面试题 02.07. 链表相交
Nacos permissions and databases
网络爬虫之短信验证