Thanks, I should have tried adding "external" before asking :)
Although, it doesn't work in EMR Hive. Table B is still 'described' as
managed so I had to run
alter table B set tblproperties('EXTERNAL'='TRUE');
along with changing the location.
Everything seems to work now!
On Mon, Mar 5, 2012
1. create external table B like A;
2. alter table B set location 's3n://'
Thanks,
Aniket
On Mon, Mar 5, 2012 at 4:59 PM, Igor Tatarinov wrote:
> Is there a way to create an external table LIKE another table?
>
> This doesn't work:
>
> CREATE TABLE B LIKE A
> ROW FORMAT DELIMITED FIELDS TERM
Is there a way to create an external table LIKE another table?
This doesn't work:
CREATE TABLE B LIKE A
ROW FORMAT DELIMITED FIELDS TERMINATED BY '\t' STORED AS TEXTFILE
LOCATION 's3://..';
FAILED: Parse Error: line 2:0 mismatched input 'ROW' expecting EOF
I tried creating a managed table B fir
Hi Vikas. You might review your logic. You probably want 'and' instead of 'or'
in your where clause.
From: hadoop hive [mailto:hadooph...@gmail.com]
Sent: Monday, March 05, 2012 5:55 AM
To: d...@hive.apache.org; user@hive.apache.org
Subject: Simple Hive Query
Hi Folks ,
i m facing a problem lik
Hi,
Your table specifies 3 ints, however, some of your rows contain strings. If you
specify you table as strings and then later parse the fields to an int (by
doing some replacements and casting it to an int), it should work.
// Wouter
On Monday, March 5, 2012 at 12:55 PM, hadoop hive wrote:
Hi Folks ,
i m facing a problem like i have a table a(k1 int ,k2 int ,k3 int );
and data present is like
*9,*1,*3
3,4,5
12,32,54
*9,12,32
12,*9,21
i need row which doesn't have *9 in any fields.
i wrote a query
1: select k1,k2,k3 from a where (k1<>'\*9' or k2<>'\*9' or k3<>'\*9');
2: selec