You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by SingoWong <si...@gmail.com> on 2010/08/26 07:09:35 UTC

Confused about after add columns for hive table

Hi,

I had execute "ALTER TABLE tablename ADD COLUMNS (newcolumns STRING)" to add
column,
before i add this column, got 4 columns, the new column will after the 4th
column, and before partition column, and now the new data in hdfs was exist
in the 5th columns, but i execute "SELECT * FROM tablename", the newcolumns
is empty.

Means i cat the file in hdfs is exist data, but how come the newcolumns is
empty?

Regards,
Singo

Re: Confused about after add columns for hive table

Posted by SingoWong <si...@gmail.com>.
resolved, thx

On Tue, Aug 31, 2010 at 2:53 AM, SingoWong <si...@gmail.com> wrote:

> everyone can help me? the columns cannot match the data~~~
>
>
> On Thu, Aug 26, 2010 at 1:09 PM, SingoWong <si...@gmail.com> wrote:
>
>> Hi,
>>
>> I had execute "ALTER TABLE tablename ADD COLUMNS (newcolumns STRING)" to
>> add column,
>> before i add this column, got 4 columns, the new column will after the 4th
>> column, and before partition column, and now the new data in hdfs was exist
>> in the 5th columns, but i execute "SELECT * FROM tablename", the newcolumns
>> is empty.
>>
>> Means i cat the file in hdfs is exist data, but how come the newcolumns is
>> empty?
>>
>> Regards,
>> Singo
>>
>
>

Re: Confused about after add columns for hive table

Posted by SingoWong <si...@gmail.com>.
everyone can help me? the columns cannot match the data~~~

On Thu, Aug 26, 2010 at 1:09 PM, SingoWong <si...@gmail.com> wrote:

> Hi,
>
> I had execute "ALTER TABLE tablename ADD COLUMNS (newcolumns STRING)" to
> add column,
> before i add this column, got 4 columns, the new column will after the 4th
> column, and before partition column, and now the new data in hdfs was exist
> in the 5th columns, but i execute "SELECT * FROM tablename", the newcolumns
> is empty.
>
> Means i cat the file in hdfs is exist data, but how come the newcolumns is
> empty?
>
> Regards,
> Singo
>