Return-Path: X-Original-To: apmail-hive-dev-archive@www.apache.org Delivered-To: apmail-hive-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B6C181057E for ; Thu, 28 Nov 2013 04:53:47 +0000 (UTC) Received: (qmail 78723 invoked by uid 500); 28 Nov 2013 04:53:41 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 78640 invoked by uid 500); 28 Nov 2013 04:53:40 -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 78632 invoked by uid 500); 28 Nov 2013 04:53:40 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 78608 invoked by uid 99); 28 Nov 2013 04:53:39 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Nov 2013 04:53:39 +0000 Date: Thu, 28 Nov 2013 04:53:39 +0000 (UTC) From: "Sushanth Sowmyan (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HIVE-5550) Import fails for tables created with default text, sequence and orc file formats using HCatalog API MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HIVE-5550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sushanth Sowmyan updated HIVE-5550: ----------------------------------- Status: Patch Available (was: Open) > Import fails for tables created with default text, sequence and orc file formats using HCatalog API > --------------------------------------------------------------------------------------------------- > > Key: HIVE-5550 > URL: https://issues.apache.org/jira/browse/HIVE-5550 > Project: Hive > Issue Type: Bug > Components: HCatalog > Affects Versions: 0.11.0 > Reporter: Venkatesh Seetharam > Assignee: Sushanth Sowmyan > Attachments: HIVE-5550.2.patch, HIVE-5550.3.patch, HIVE-5550.patch > > > A table was created using HCatalog API with out specifying the file format, it defaults to: > {code} > fileFormat=TextFile, inputformat=org.apache.hadoop.mapred.TextInputFormat, outputformat=org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat > {code} > But, when hive fetches the table from the metastore, it strangely replaces the output format with org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat > and the comparison between source and target table fails. > The code in org.apache.hadoop.hive.ql.parse.ImportSemanticAnalyzer#checkTable does a string comparison of classes and fails. > {code} > // check IF/OF/Serde > String existingifc = table.getInputFormatClass().getName(); > String importedifc = tableDesc.getInputFormat(); > String existingofc = table.getOutputFormatClass().getName(); > String importedofc = tableDesc.getOutputFormat(); > if ((!existingifc.equals(importedifc)) > || (!existingofc.equals(importedofc))) { > throw new SemanticException( > ErrorMsg.INCOMPATIBLE_SCHEMA > .getMsg(" Table inputformat/outputformats do not match")); > } > {code} > This only affects tables with text and sequence file formats but not rc or orc. -- This message was sent by Atlassian JIRA (v6.1#6144)