Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 2C9BC200C1C for ; Wed, 15 Feb 2017 12:56:55 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 2B439160B5E; Wed, 15 Feb 2017 11:56:55 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 7585D160B46 for ; Wed, 15 Feb 2017 12:56:54 +0100 (CET) Received: (qmail 50903 invoked by uid 500); 15 Feb 2017 11:56:53 -0000 Mailing-List: contact dev-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list dev@hive.apache.org Received: (qmail 50892 invoked by uid 99); 15 Feb 2017 11:56:53 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 15 Feb 2017 11:56:53 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id DAD991A07D7 for ; Wed, 15 Feb 2017 11:56:52 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.999 X-Spam-Level: X-Spam-Status: No, score=-1.999 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id Mi1yi6LU4iws for ; Wed, 15 Feb 2017 11:56:52 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id D65BF5F3BD for ; Wed, 15 Feb 2017 11:56:51 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 09232E02F7 for ; Wed, 15 Feb 2017 11:56:41 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id A6BE92411B for ; Wed, 15 Feb 2017 11:56:41 +0000 (UTC) Date: Wed, 15 Feb 2017 11:56:41 +0000 (UTC) From: "JaySenSharma (JIRA)" To: dev@hive.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (HIVE-15927) HIve does not insert UTF-8 characters properly when insert query is triggered. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 15 Feb 2017 11:56:55 -0000 JaySenSharma created HIVE-15927: ----------------------------------- Summary: HIve does not insert UTF-8 characters properly when i= nsert query is triggered. Key: HIVE-15927 URL: https://issues.apache.org/jira/browse/HIVE-15927 Project: Hive Issue Type: Bug Components: Hive Affects Versions: 1.2.1, 1.2.0 Environment: All Reporter: JaySenSharma -=20 If we create a table as following from Ambari Hive View (or using any other= approach) {code} CREATE TABLE IF NOT EXISTS currency2 (id int, name string) ROW FORMAT SERDE= 'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe' WITH SERDEPROPERTIES(= "serialization.encoding"=3D'UTF-8','store.charset'=3D'UTF-8', 'retrieve.cha= rset'=3D'UTF-8'); INSERT INTO currency2 VALUES (1, "=C2=A3=E2=82=AC=E2=82=A1"); SELECT * FROM currency2; {code} - Output from ambari side is attached as "Result.png" Here we see that the queries were sent to the "hive" correctly as we see th= e following entries appear in the "hiveserver2.log" {code} ssh root@hiveserevr2host cd /var/log/hive tail -f hiveserver2.log {code} Output of the log shows that hiveserver2 received the proper insert query s= tatements from Ambari Hive View. {code} 2017-01-25 09:25:27,589 INFO [HiveServer2-Handler-Pool: Thread-60]: parse.= ParseDriver (ParseDriver.java:parse(185)) - Parsing command: INSERT INTO cu= rrency2 VALUES (1, "=C2=A3=E2=82=AC=E2=82=A1") 2017-01-25 09:25:28,337 INFO [HiveServer2-Background-Pool: Thread-244]: ex= ec.Task (TezTask.java:build(316)) - Dag name: INSERT INTO currency2 VALUES = (1, "=C2=A3=E2=82=AC=E2=82=A1")(Stage-1) 2017-01-25 09:25:28,694 INFO [HiveServer2-Background-Pool: Thread-244]: cl= ient.TezClient (TezClient.java:submitDAGSession(577)) - Submitted dag to Te= zSession, sessionName=3DHIVE-bf038f08-853a-4850-80bc-7a6eaded3c2d, applicat= ionId=3Dapplication_1485333705258_0007, dagName=3DINSERT INTO c urrency1 VALUES (1, "=C2=A3=E2=82=AC=E2=82=A1")(Stage-1) {code} - Even the beeline fails to show the correct entry: {code} [root@erie3 ~]# su - hive [hive@erie3 root]$ beeline Beeline version 1.2.1000.2.5.3.0-37 by Apache Hive beeline> !connect jdbc:hive2://erie3.example.com:2181,erie1.example.com:218= 1,erie4.example.com:2181,erie2.example.com:2181/;serviceDiscoveryMode=3Dzoo= Keeper;zooKeeperNamespace=3Dhiveserver2 0: jdbc:hive2://erie3.example.com:2181,erie1.> SELECT * FROM currency2; +---------------+-----------------+--+ | currency2.id | currency2.name | +---------------+-----------------+--+ | 1 | =EF=BF=BD=EF=BF=BD=EF=BF=BD | +---------------+-----------------+--+ {code} -- This message was sent by Atlassian JIRA (v6.3.15#6346)