Return-Path: X-Original-To: apmail-hive-user-archive@www.apache.org Delivered-To: apmail-hive-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C059ADA29 for ; Mon, 5 Nov 2012 15:56:38 +0000 (UTC) Received: (qmail 49283 invoked by uid 500); 5 Nov 2012 15:56:37 -0000 Delivered-To: apmail-hive-user-archive@hive.apache.org Received: (qmail 49003 invoked by uid 500); 5 Nov 2012 15:56:36 -0000 Mailing-List: contact user-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hive.apache.org Delivered-To: mailing list user@hive.apache.org Received: (qmail 48974 invoked by uid 99); 5 Nov 2012 15:56:35 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Nov 2012 15:56:35 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of edlinuxguru@gmail.com designates 209.85.223.176 as permitted sender) Received: from [209.85.223.176] (HELO mail-ie0-f176.google.com) (209.85.223.176) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Nov 2012 15:56:31 +0000 Received: by mail-ie0-f176.google.com with SMTP id k11so9373461iea.35 for ; Mon, 05 Nov 2012 07:56:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=/LOubKueCIjEDFNbOH0x3+blTUxu9eHf47G7jkN51e0=; b=BuOcDO02j894mlIEg747xknKycFK4H4egK13jMm9wLTsfp1/o5HHiuOOknoXUirTtt tPEpvwMV4bszXzuH8JNGsMx2kXio472lG0ZcjXCgOW2/f6dqFL5bdntz6koxq3/16wdL k/w8GQQdRsAp3Q+mR58fKzByPFiJVJ/CeHsFAFaKAecsgRhKdPfnkH5vTm91w+AlkLBG njhNtwWr0yQ/Pk5KXpdZ/cjRYsAvWQeJ6cmD2913gKm/8yDBXu3GMZYQzBsHKUEggAIE CI9Aodu4TRASAAuD6ctmu6t9soA5E4mIem6TozTZIf7aSDtr45+q1Yiz6amfJI9RfHIA AERA== MIME-Version: 1.0 Received: by 10.50.237.103 with SMTP id vb7mr9883684igc.29.1352130970854; Mon, 05 Nov 2012 07:56:10 -0800 (PST) Received: by 10.64.97.106 with HTTP; Mon, 5 Nov 2012 07:56:10 -0800 (PST) In-Reply-To: References: Date: Mon, 5 Nov 2012 10:56:10 -0500 Message-ID: Subject: Re: Alter table is giving error From: Edward Capriolo To: user@hive.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org Recover partitions should work the same way for different file systems. Edward On Mon, Nov 5, 2012 at 9:33 AM, Dean Wampler wrote: > Writing a script to add the external partitions individually is the only way > I know of. > > Sent from my rotary phone. > > > On Nov 5, 2012, at 8:19 AM, Chunky Gupta wrote: > > Hi Dean, > > Actually I was having Hadoop and Hive cluster on EMR and I have S3 storage > containing logs which updates daily and having partition with date(dt). And > I was using this recover partition. > Now I wanted to shift to EC2 and have my own Hadoop and Hive cluster. So, > what is the alternate of using recover partition in this case, if you have > any idea ? > I found one way of individually partitioning all dates, so I have to write > script for that to do so for all dates. Is there any easiest way other than > this ? > > Thanks, > Chunky > > > > On Mon, Nov 5, 2012 at 6:28 PM, Dean Wampler > wrote: >> >> The RECOVER PARTITIONS is an enhancement added by Amazon to their version >> of Hive. >> >> >> http://docs.amazonwebservices.com/ElasticMapReduce/latest/DeveloperGuide/emr-hive-additional-features.html >> >> >> Chapter 21 of Programming Hive discusses this feature and other aspects >> of using Hive in EMR. >> >> >> dean >> >> >> On Mon, Nov 5, 2012 at 5:34 AM, Chunky Gupta >> wrote: >>> >>> Hi, >>> >>> I am having a cluster setup on EC2 with Hadoop version 0.20.2 and Hive >>> version 0.8.1 (I configured everything) . I have created a table using :- >>> >>> CREATE EXTERNAL TABLE XXX ( YYY )PARTITIONED BY ( ZZZ )ROW FORMAT >>> DELIMITED FIELDS TERMINATED BY 'WWW' LOCATION 's3://my-location/data/'; >>> >>> Now I am trying to recover partition using :- >>> >>> ALTER TABLE XXX RECOVER PARTITIONS; >>> >>> but I am getting this error :- "FAILED: Parse Error: line 1:12 cannot >>> recognize input near 'XXX' 'RECOVER' 'PARTITIONS' in alter table statement" >>> >>> Doing same steps on a cluster setup on EMR with Hadoop version 1.0.3 and >>> Hive version 0.8.1 (Configured by EMR), works fine. >>> >>> So is this a version issue or am I missing some configuration changes in >>> EC2 setup ? >>> I am not able to find exact solution for this problem on internet. Please >>> help me. >>> >>> Thanks, >>> Chunky. >>> >>> >>> >> >> >> >> -- >> Dean Wampler, Ph.D. >> thinkbiganalytics.com >> +1-312-339-1330 >> >> >