当前位置:网站首页>2Gcsv文件打不开怎么处理,使用byzer工具
2Gcsv文件打不开怎么处理,使用byzer工具
2022-06-26 15:06:00 【MonkeyKing_sunyuhua】
项目需要,需要将客户的环境的数据导出来做对对账分析,客户数据隐秘,不能提供调用接口,需要只能以csv文件的形式发出来。
但是一个2G的csv文件,大部分机器都会自己崩溃。还有一个方法就是拆分工具拆分,但是拆分后分析数据比较麻烦。
有一款Byzer的工具可以满足这个需求
官网地址:
支持私有环境部署,保证数据的隐私,搭建环境如下:
1、准备一台liunx机器,机器配置2核8G左右
2、下载byzer并安装
wget https://download.byzer.org/byzer/2.3.0.1/byzer-lang-all-in-one-linux-amd64-3.1.1-2.3.0.1.tar.gz
tar -zxvf byzer-lang-all-in-one-linux-amd64-3.1.1-2.3.0.1.tar.gz
cd byzer-lang-all-in-one-linux-amd64-3.1.1-2.3.0.1
3、启动byzer
./bin/byzer.sh start
4.可以访问byzer,但是不太友好,可以安装配套的可视化工具notebook

5、下载并安装notebook
wget https://download.byzer.org/byzer-notebook/1.2.0/Byzer-Notebook-1.2.0.tar.gz
tar -xvf Byzer-Notebook-1.2.0.tar.gz
6、notebook依赖mysql,需要提前安装一下mysql
可以使用docker-compose安装,其他的安装方式,自己百度一下
docker-compose.yml 文件
version: "2"
services:
mysql:
container_name: mysql
image: mysql:5.7
restart: always
volumes:
- ./mysql/data:/var/lib/mysql
- ./mysql/init:/docker-entrypoint-initdb.d
- /etc/localtime:/etc/localtime:ro
ports:
- "3306:3306"
environment:
MYSQL_ROOT_PASSWORD: "XXXXX"
TZ: "Asia/Shanghai"
command: --max_allowed_packet=32505856
7、调整notebook关于mysql的配置

路径地址
cd /home/Byzer-Notebook-1.2.0/conf

8、启动notebook
./bin/notebook.sh start

9.注册后即可访问使用

10、点击上传,上传自己的2G的csv文件


因为是2G的文件,上传比较慢,这里需要耐心的等待
11、新建笔记本,对文件进行查看

12、将刚刚导出的csv转化为表结构
load csv.`/tmp/upload/billing.csv` where header="true" as r3;
如果是xlsx文件
load excel.`/tmp/upload/billing.xlsx` where header="true" as r4;
注意
这里是反引号,不是单引号
13、至此就可以查看使用
select * from r3 limit 10 as 2022_06_24_r3;
在这里插入代码片
注意后面要带上 “as 表的别名” 这可能是byzer的特殊的标记方式。
select sum(BlendedCost) from r3 where payerAccountId=417966497442 as 417966497442_count;
支持所有的sql查询方式


附注:
如果出现这个错误,检查一下环境的JDK配置

如果出现访问不了9002,9003端口,检查一下安全组的设置
边栏推荐
- shell脚本多进程并发写法实例(高阶修炼)
- Redis集群消息
- 【TcaplusDB知识库】TcaplusDB单据受理-事务执行介绍
- HR export data Excel VBA
- Sikuli 基于图形识别的自动化测试技术
- R language dplyr package bind_ The rows function merges the rows of the two dataframes vertically. The final number of rows is the sum of the rows of the original two dataframes (combine data frames)
- 【TcaplusDB知识库】TcaplusDB运维单据介绍
- Shell script multi process concurrent writing method example (high level cultivation)
- R language dplyr package summary_ The at function calculates the mean and median of multiple data columns (specified by vectors) in the dataframe data, and specifies na RM parameter configuration dele
- TS common data types summary
猜你喜欢

小程序:uniapp解决 vendor.js 体积过大的问题

1.会计基础--会计的几大要素(会计总论、会计科目和账户)

【ceph】CephFS 内部实现(二):示例--未消化

ETL过程中数据精度不准确问题

Halcon C# 设置窗体字体,自适应显示图片

数据库-视图

RestCloud ETL抽取動態庫錶數據實踐

【TcaplusDB知识库】TcaplusDB OMS业务人员权限介绍

使用卷积对数据进行平滑处理

The heavyweight white paper was released. Huawei continues to lead the new model of smart park construction in the future
随机推荐
使用RestCloud ETL Shell组件实现定时调度DataX离线任务
vue中缓存页面 keepAlive使用
TCP 复位攻击原理
使用卷积对数据进行平滑处理
10分钟了解BIM+GIS融合,常见BIM数据格式及特性
Redis cluster re fragmentation and ask command
【TcaplusDB知识库】TcaplusDB OMS业务人员权限介绍
Using restcloud ETL shell component to schedule dataX offline tasks
Notes on brushing questions (19) -- binary tree: modification and construction of binary search tree
[tcapulusdb knowledge base] tcapulusdb system user group introduction
MongoDB系列之Window环境部署配置
【TcaplusDB知识库】TcaplusDB常规单据介绍
BLE抓包调试信息分析
Talk about the RPA direction planning: stick to simple and valuable things for a long time
Pytoch deep learning code skills
【TcaplusDB知识库】TcaplusDB单据受理-建表审批介绍
shell脚本多进程并发写法实例(高阶修炼)
Is it safe to open a stock account through the account opening link given by the broker manager? I want to open an account
Applet: uniapp solves vendor JS is too large
Shell script multi process concurrent writing method example (high level cultivation)