Grokbase Groups Hive user April 2011
FAQ
Hi Prash,

Try this:

create external table mslog
(
time_stamp string,
seq string
) row format delimited fields terminated by '\t' stored as textfile location 's3://your/bucket/path/'
;

Important: your s3 bucket can only contain files that have the same schema format. Hive doesn't like it when the bucket contains files with a mixture of different columns.
Also, check your logs if you don't think your data was successfully read.

Hope this helps,
~Avram

On Apr 11, 2011, at 2:09 PM, Prashanth R wrote:

Hi,

The Hive documentation describes keyword "external" as following:

The EXTERNAL keyword lets you create a table and provide a LOCATION so that Hive does not use a default location for this table. This comes in handy if you already have data generated.

I have my data available in a directory in a bucket in s3. I am trying to create a table like

CREATE EXTERNAL TABLE IF NOT EXISTS mslog ( TIME_STAMP STRING, SEQ STRING) LOCATION 's3:// <bucket name>/processed/'

But the table isnt' populated with the data available at the s3 location. Am i missing something here?


--
- Prash

Search Discussions

Discussion Posts

Previous

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 3 of 3 | next ›
Discussion Overview
groupuser @
categorieshive, hadoop
postedApr 11, '11 at 9:10p
activeApr 12, '11 at 4:51p
posts3
users3
websitehive.apache.org

People

Translate

site design / logo © 2021 Grokbase