Linux shell Programming implementation of the ETL based on Hadoop (analysis) __HTML5

Source: Internet
Author: User
Tags psql

Gathen: 397706991, learning together

Conf/hive.xml

Specific shell code Download: http://download.csdn.net/detail/luo849278597/9490920

<?xml version= "1.0" encoding= "UTF-8"?>
<root>
	
bin/hive.sh
#!/bin/bash ######################## #以下命令的处理基于Hadoop环境以及Hive工具, and the corresponding tool commands need to be defined #sed命令是Shell编程中用于处理字符串 in the environment variable, The command to filter out the required string #tr-d ' r ' is used to delete line breaks in each row #eval used to execute string commands ######################## #get the environment if [-f ~/.BASHRC]; #进入B Ash shell command, for execution then of the following command. ~/.BASHRC fi #file exit if [-Z $]; Then #判断配置文件是否存在 Echo ' Usage:command FILENAME ' exit 0 fi #预定义变量以及数组 declare-a analysis_sqls declare-i i=0 flag=0 cont Ent= ' Sed-e ' s/\s*\ (. *\) \s*$/\1/g '-E ' s/\s*\ (=\) \s*/\1/g '-E '/^\ (\s\) *$/d '-e '/^$/d '-e ' s/<!--. *-->//' $ ' whil E read line do if echo ${line}|grep-qe "^
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.