GithubHelp home page GithubHelp logo

file2hive's Introduction

           1)运行环境:服务器、或其他装好依赖的linux系统(依赖: pyhoon3、pyhive、hiveserver2)

           2)运行说明:python3 load_data.py  路径文件名(默认当前路径)  编码方式(gbk 或者 utf-8)   模式(0或1)

                                  需要在调用时传入以上三个参数:

                                         a)路径文件名 :只写文件名默认当前路径(路径写相对路径,如父目录123.csv文件,可写  ‘../123.csv’)

                                         b)  编码方式:数据文件的编码方式 一般为gbk或utf-8

                                         c)  模式:0或1两个模式。模式0为不指定表头纯数据导入,即导入数据文件后每列

                                                         的字段名为c0、c1、c2...

                                                         模式1为指定表头导入,将按数据文件的第一行内容作为表字段名,其他

                                                         行作为数据,此处用英文还要注意填入的编码问题。

           3)生成的表名为:otemp.temp_load_文件名

            举例:

                     终端执行:python3   load_csv.py   123.csv   gbk   0

                     导入当前路径文件123.csv, 编码方式为gbk  模式为0

file2hive's People

Contributors

felixjie avatar

Stargazers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.