1. Create the lib121 directory under the hive0.13.1 version
Cd/opt/cloudera/parcels/cdh/lib/hive;mkdir lib1212. Download the hive1.2.1 version and copy all files from this version of Lib to lib121
3. Modify the Hive_lib variable in/opt/cloudera/parcels/cdh/lib/hive/bin/hive
hive_lib=${hive_home}/lib121
4. Update the JLine jar package on Hadoop and remove the ol
1. Hive's inner tableThe inner table of Hive is the normally created table, which is already mentioned in http://www.cnblogs.com/raphael5200/p/5208437.html;2, the appearance of hiveTo create a hive's appearance, you need to use the keyword External:CREATE EXTERNAL TABLE [IF not EXISTS] [db_name.] TABLE_NAME [(col_name data_type [COMMENT col_comment], ...)] [COMMENT Table_comment] [Partitioned by (Col_name data_type [COMMENT col_comment], ...)]
The hive Custom function consists of three UDFs, UDAF, UDTFUDF (User-defined-function) one in and outUDAF (user-defined Aggregation funcation) aggregation function, the more in one out. Count/max/minUDTF (user-defined table-generating Functions) One more step out, such as lateral view explore ()How to use: Add a custom function's jar file in a hive session, and then create a function to use itUdf1, the UDF
HIVE-UDF operationOperation procedure of UDF:Add A custom function to the jar file in the HIVE session , and then create the function, The function is then used. Below is an example of the following topics:Topic: Statistics of PV and UV for each activityFirst, Java through the regular expression, intercept the title name.Take a link to intercept the red string.http://cms.yhd.com/sale/vtxqclczfto? tc=ad.0.0.
1. Download the source code on the hive's official website and upload it to the server2. Go to the directory to unzipTAR-ZXVF apache-hive-0.14.0-src.tar.gz3. Go to the web directoryCD APACHE-HIVE-0.14.0-SRCCD Hwi/web4. Make the Web source into a zip packageZip hive-hwi-0.14.0.zip./*//packaged into a. zip file.5. Change the zip suffix to warHive-hwi-0.14.0.war6. C
"Programming Hive" Reading notes (two) Hive basics: first read is browse. Build knowledge index, because some knowledge may not be able to use, know is good. The parts of interest can be studied more. After the use of the time to look specifically. and combined with other materials.Chapter 3.Data Types and File FormatsRaw data types and collection data typesSelect out of data, the delimiter between columns
Part I: Building a hive JDBC development environmentBuild:Steps ? New project Hivetest? Import hive-dependent packages? Hive Command line start thrift service? Hive--service Hiveserver Part Two: Introduction of basic Operation ObjectsConnectionDescription: The connection object connected to
One, hive command line 1, hive support some of the commands
Command Description
quit Use quit or exit to leave the interactive shell.
Set Key=value Use the To set value of particular configuration variable. One thing to note here's if you misspell the variable name, the CLI won't show an error.
Set This would print a list of configuration variables that is overridden by user or
Describe:Hive Table Pms.cross_sale_path is established with the date as the partition, the HDFs directory/user/pms/workspace/ouyangyewei/testusertrack/job1output/ The data on the Crosssale, written on the $yesterday partition of the tableTable structure:HIVE-E "Set Mapred.job.queue.name=pms;drop table if exists pms.cross_sale_path;create external table Pms.cross_sale_ Path (track_id string,track_time string,session_id string,gu_id string,end_user_id string,page_category_id bigint, algorithm_id i
Read the table structure in hive. This article contains the table class, the field class is used to encapsulate the table structure, and it will be OK after a rough look.
(Change the code format)
1. Table class
Public class table {
Private string tablename;
Private list
Public table (){
}
Public table (string tablename, list
This. tablename = tablename;
This. Field = field;
}
Public String gettablename (){
Return tablename;
}
Public void setta
Tags: Word exist Derby configuration driver data pre XML color / /server110:3306/hive?createdatabaseifnotexist=true
Hive replaces default Derby's hive-site.xml configuration with MySQL as metadata
Hive The main features of each version
Introduction to Key new Feature of Hive versions
The website downloads the introduction of the page
Hive Foundationcommand-line interface
The user interface provided by hive includes: CLI, Client, WebUI several ways, we usually mainly use CLI, the future cluster upgrade may have
Explain syntax
Hive provides the explain command to display the query execution plan. Syntax:
Explain [extended] Query
The explain statement uses extended to provide additional information about the operation in the execution plan. This is a typical physical information, such as a file name.
Hive queries are converted into sequences (this is a directed acyclic graph. These stages may be mapper/reduc
Hive has two data modification methods
Load from file to hive table
Hive does not perform any conversion when loading data to a table. The loading operation is a pure copy/move operation, which moves data files to the corresponding hive table.
Syntax
Load data [local] inpath 'filepath' [overwrite] into Table ta
Detailed description of how Mysql metadata generates Hive table creation statement annotation scripts, and metadata hive
Preface
This article describes how to generate a script for commenting on Hive table creation statements generated by Mysql metadata for your reference. I will not talk about it here. Let's take a look at the detailed introduction:
Recently, wh
Label: First,Eclipse new Other-"map/reduce Project Project The project automatically contains the jar packages of the associated Hadoop, In addition, you will need to import the following hive and the MySQL-connected jar package separately: Hive/lib/*.jar Mysql-connector-java-5.1.24-bin.jar Second, the shipment hiveserver Command: bin/hive--service Hiveserver
1. Missing MySQL driver package
1.1 Problem Description
caused by:org.datanucleus.store.rdbms.connectionpool.DatastoreDriverNotFoundException:The specified datastore Driver ("Com.mysql.jdbc.Driver") was wasn't found in the CLASSPATH. Please check your CLASSPATH specification, and the name of the driver.
At Org.datanucleus.store.rdbms.connectionpool.AbstractConnectionPoolFactory.loadDriver ( abstractconnectionpoolfactory.java:58) at
Org.datanucleus.store.rdbms.connectionpool.BoneCPConnectionP
Written in front one:
In this paper, hive and hbase are integrated so that hive can read the data in HBase, so that the two most commonly used frameworks in the Hadoop ecosystem are combined to complement each other.
Written in front two:
Use software description
To contract all software storage directory:
/home/yujianxin
First, hive integrated hbase pr
Overview
As long as the correct file types and compression types (such as Textfile+gzip, sequencefile+snappy, etc.) are configured, hive can read and parse data as expected and provide SQL functionality.
The structure of the sequencefile itself has been designed to compress content. So for the Sequencefile file compression, not the Sequencefile file, and then the file compression. Instead, the Content field is compressed when the Sequencefile file is
Hive simple instructions for use, hive simple instructions for use
I usage:
Hive: Start hive
The command must end with a semicolon and tell hive to execute the command immediately, case insensitive.
Show tables; View tables
Desc tablename; view the columns in the tabl
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.