You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hadoop.apache.org by unmesha sreeveni <un...@gmail.com> on 2014/11/17 05:30:10 UTC

Values getting duplicated in Hive table(Partitioned)

I created a Hive table with *partition* and inserted data into Partioned
Hive table.

Refered site
<https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>

   1.

   *Initially created one Non -partioned table and then using select query
   and loaded data into partioned table. Is there an alternate way?*
   2.

   *By following above link my partioned table contains duplicate values.
   Below are the setps*

This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>

I tried the following queries: link2 <http://pastebin.com/U2yykWpy>

But after updating a value in Hive table,the values are getting duplicated.

7       Nirmal  Tech    12000   A
7       Nirmal  Tech    12000   B

Nirmal is placed in Department *A* only
​,​
but it is duplicated to department *B*.

And Once I update a column value in middle I am getting NULL values
displayed,while updating last column it is fine.

Am I doing any thing wrong.
Please suggest.--
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Re: Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
Thanks it worked.
On Nov 17, 2014 3:32 PM, "unmesha sreeveni" <un...@gmail.com> wrote:

>
> ---------- Forwarded message ----------
> From: unmesha sreeveni <un...@gmail.com>
> Date: Mon, Nov 17, 2014 at 10:49 AM
> Subject: Re: Values getting duplicated in Hive table(Partitioned)
> To: User - Hive <us...@hive.apache.org>
>
>
> In non partitioned table I am getting the correct values.
>
> Is my update query wrong?
>
>    1. INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A')
>    SELECT employeeid,firstname,designation, CASE WHEN employeeid=19 THEN
>    '50000 ELSE salary END AS salary FROM Unm_Parti_Trail;
>
> What I tried to include in the query is , In partion with department = A,
> update employeeid =19 's salary with 50000
>
> Is that query statement wrong? and the replication is not affected to dept
> B and C.
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>
>
>
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>

Re: Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
Thanks it worked.
On Nov 17, 2014 3:32 PM, "unmesha sreeveni" <un...@gmail.com> wrote:

>
> ---------- Forwarded message ----------
> From: unmesha sreeveni <un...@gmail.com>
> Date: Mon, Nov 17, 2014 at 10:49 AM
> Subject: Re: Values getting duplicated in Hive table(Partitioned)
> To: User - Hive <us...@hive.apache.org>
>
>
> In non partitioned table I am getting the correct values.
>
> Is my update query wrong?
>
>    1. INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A')
>    SELECT employeeid,firstname,designation, CASE WHEN employeeid=19 THEN
>    '50000 ELSE salary END AS salary FROM Unm_Parti_Trail;
>
> What I tried to include in the query is , In partion with department = A,
> update employeeid =19 's salary with 50000
>
> Is that query statement wrong? and the replication is not affected to dept
> B and C.
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>
>
>
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>

Re: Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
Thanks it worked.
On Nov 17, 2014 3:32 PM, "unmesha sreeveni" <un...@gmail.com> wrote:

>
> ---------- Forwarded message ----------
> From: unmesha sreeveni <un...@gmail.com>
> Date: Mon, Nov 17, 2014 at 10:49 AM
> Subject: Re: Values getting duplicated in Hive table(Partitioned)
> To: User - Hive <us...@hive.apache.org>
>
>
> In non partitioned table I am getting the correct values.
>
> Is my update query wrong?
>
>    1. INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A')
>    SELECT employeeid,firstname,designation, CASE WHEN employeeid=19 THEN
>    '50000 ELSE salary END AS salary FROM Unm_Parti_Trail;
>
> What I tried to include in the query is , In partion with department = A,
> update employeeid =19 's salary with 50000
>
> Is that query statement wrong? and the replication is not affected to dept
> B and C.
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>
>
>
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>

Re: Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
Thanks it worked.
On Nov 17, 2014 3:32 PM, "unmesha sreeveni" <un...@gmail.com> wrote:

>
> ---------- Forwarded message ----------
> From: unmesha sreeveni <un...@gmail.com>
> Date: Mon, Nov 17, 2014 at 10:49 AM
> Subject: Re: Values getting duplicated in Hive table(Partitioned)
> To: User - Hive <us...@hive.apache.org>
>
>
> In non partitioned table I am getting the correct values.
>
> Is my update query wrong?
>
>    1. INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A')
>    SELECT employeeid,firstname,designation, CASE WHEN employeeid=19 THEN
>    '50000 ELSE salary END AS salary FROM Unm_Parti_Trail;
>
> What I tried to include in the query is , In partion with department = A,
> update employeeid =19 's salary with 50000
>
> Is that query statement wrong? and the replication is not affected to dept
> B and C.
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>
>
>
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>

Re: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
In non partitioned table I am getting the correct values.

Is my update query wrong?

   1. INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A')
   SELECT employeeid,firstname,designation, CASE WHEN employeeid=19 THEN
   '50000 ELSE salary END AS salary FROM Unm_Parti_Trail;

What I tried to include in the query is , In partion with department = A,
update employeeid =19 's salary with 50000

Is that query statement wrong? and the replication is not affected to dept
B and C.
-- 
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
In non partitioned table I am getting the correct values.

Is my update query wrong?

INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A') SELECT
employeeid,firstname,designation, CASE WHEN employeeid=19 THEN '50000 ELSE
salary END AS salary FROM Unm_Parti_Trail;


What I tried to include in the query is , In partion with department = A,
update employeeid =19 's salary with 50000

Is that query statement wrong? and the replication is not affected to dept
B and C


---------- Forwarded message ----------
From: hadoop hive <ha...@gmail.com>
Date: Mon, Nov 17, 2014 at 10:08 AM
Subject: Re: Values getting duplicated in Hive table(Partitioned)
To: user@hive.apache.org


Can you check your select query to run on non partitioned tables. Check if
it's giving correct values.

Same as for dept. B
 On Nov 17, 2014 10:03 AM, "unmesha sreeveni" <un...@gmail.com> wrote:

> ***I created a Hive table with *non*- *partitioned* and using select
> query I inserted data into *Partioned* Hive table.
>
> On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
> wrote:
>
>> I created a Hive table with *partition* and inserted data into Partioned
>> Hive table.
>>
>> Refered site
>> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>>
>>    1.
>>
>>    *Initially created one Non -partioned table and then using select
>>    query and loaded data into partioned table. Is there an alternate way?*
>>    2.
>>
>>    *By following above link my partioned table contains duplicate
>>    values. Below are the setps*
>>
>> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>>
>> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>>
>> But after updating a value in Hive table,the values are getting
>> duplicated.
>>
>> 7       Nirmal  Tech    12000   A
>> 7       Nirmal  Tech    12000   B
>>
>> Nirmal is placed in Department *A* only
>> ​,​
>> but it is duplicated to department *B*.
>>
>> And Once I update a column value in middle I am getting NULL values
>> displayed,while updating last column it is fine.
>>
>> Am I doing any thing wrong.
>> Please suggest.--
>>
>
> --
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
In non partitioned table I am getting the correct values.

Is my update query wrong?

INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A') SELECT
employeeid,firstname,designation, CASE WHEN employeeid=19 THEN '50000 ELSE
salary END AS salary FROM Unm_Parti_Trail;


What I tried to include in the query is , In partion with department = A,
update employeeid =19 's salary with 50000

Is that query statement wrong? and the replication is not affected to dept
B and C


---------- Forwarded message ----------
From: hadoop hive <ha...@gmail.com>
Date: Mon, Nov 17, 2014 at 10:08 AM
Subject: Re: Values getting duplicated in Hive table(Partitioned)
To: user@hive.apache.org


Can you check your select query to run on non partitioned tables. Check if
it's giving correct values.

Same as for dept. B
 On Nov 17, 2014 10:03 AM, "unmesha sreeveni" <un...@gmail.com> wrote:

> ***I created a Hive table with *non*- *partitioned* and using select
> query I inserted data into *Partioned* Hive table.
>
> On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
> wrote:
>
>> I created a Hive table with *partition* and inserted data into Partioned
>> Hive table.
>>
>> Refered site
>> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>>
>>    1.
>>
>>    *Initially created one Non -partioned table and then using select
>>    query and loaded data into partioned table. Is there an alternate way?*
>>    2.
>>
>>    *By following above link my partioned table contains duplicate
>>    values. Below are the setps*
>>
>> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>>
>> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>>
>> But after updating a value in Hive table,the values are getting
>> duplicated.
>>
>> 7       Nirmal  Tech    12000   A
>> 7       Nirmal  Tech    12000   B
>>
>> Nirmal is placed in Department *A* only
>> ​,​
>> but it is duplicated to department *B*.
>>
>> And Once I update a column value in middle I am getting NULL values
>> displayed,while updating last column it is fine.
>>
>> Am I doing any thing wrong.
>> Please suggest.--
>>
>
> --
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
In non partitioned table I am getting the correct values.

Is my update query wrong?

INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A') SELECT
employeeid,firstname,designation, CASE WHEN employeeid=19 THEN '50000 ELSE
salary END AS salary FROM Unm_Parti_Trail;


What I tried to include in the query is , In partion with department = A,
update employeeid =19 's salary with 50000

Is that query statement wrong? and the replication is not affected to dept
B and C


---------- Forwarded message ----------
From: hadoop hive <ha...@gmail.com>
Date: Mon, Nov 17, 2014 at 10:08 AM
Subject: Re: Values getting duplicated in Hive table(Partitioned)
To: user@hive.apache.org


Can you check your select query to run on non partitioned tables. Check if
it's giving correct values.

Same as for dept. B
 On Nov 17, 2014 10:03 AM, "unmesha sreeveni" <un...@gmail.com> wrote:

> ***I created a Hive table with *non*- *partitioned* and using select
> query I inserted data into *Partioned* Hive table.
>
> On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
> wrote:
>
>> I created a Hive table with *partition* and inserted data into Partioned
>> Hive table.
>>
>> Refered site
>> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>>
>>    1.
>>
>>    *Initially created one Non -partioned table and then using select
>>    query and loaded data into partioned table. Is there an alternate way?*
>>    2.
>>
>>    *By following above link my partioned table contains duplicate
>>    values. Below are the setps*
>>
>> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>>
>> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>>
>> But after updating a value in Hive table,the values are getting
>> duplicated.
>>
>> 7       Nirmal  Tech    12000   A
>> 7       Nirmal  Tech    12000   B
>>
>> Nirmal is placed in Department *A* only
>> ​,​
>> but it is duplicated to department *B*.
>>
>> And Once I update a column value in middle I am getting NULL values
>> displayed,while updating last column it is fine.
>>
>> Am I doing any thing wrong.
>> Please suggest.--
>>
>
> --
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Fwd: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
In non partitioned table I am getting the correct values.

Is my update query wrong?

INSERT OVERWRITE TABLE Unm_Parti_Trail PARTITION (Department = 'A') SELECT
employeeid,firstname,designation, CASE WHEN employeeid=19 THEN '50000 ELSE
salary END AS salary FROM Unm_Parti_Trail;


What I tried to include in the query is , In partion with department = A,
update employeeid =19 's salary with 50000

Is that query statement wrong? and the replication is not affected to dept
B and C


---------- Forwarded message ----------
From: hadoop hive <ha...@gmail.com>
Date: Mon, Nov 17, 2014 at 10:08 AM
Subject: Re: Values getting duplicated in Hive table(Partitioned)
To: user@hive.apache.org


Can you check your select query to run on non partitioned tables. Check if
it's giving correct values.

Same as for dept. B
 On Nov 17, 2014 10:03 AM, "unmesha sreeveni" <un...@gmail.com> wrote:

> ***I created a Hive table with *non*- *partitioned* and using select
> query I inserted data into *Partioned* Hive table.
>
> On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
> wrote:
>
>> I created a Hive table with *partition* and inserted data into Partioned
>> Hive table.
>>
>> Refered site
>> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>>
>>    1.
>>
>>    *Initially created one Non -partioned table and then using select
>>    query and loaded data into partioned table. Is there an alternate way?*
>>    2.
>>
>>    *By following above link my partioned table contains duplicate
>>    values. Below are the setps*
>>
>> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>>
>> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>>
>> But after updating a value in Hive table,the values are getting
>> duplicated.
>>
>> 7       Nirmal  Tech    12000   A
>> 7       Nirmal  Tech    12000   B
>>
>> Nirmal is placed in Department *A* only
>> ​,​
>> but it is duplicated to department *B*.
>>
>> And Once I update a column value in middle I am getting NULL values
>> displayed,while updating last column it is fine.
>>
>> Am I doing any thing wrong.
>> Please suggest.--
>>
>
> --
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Re: Values getting duplicated in Hive table(Partitioned)

Posted by hadoop hive <ha...@gmail.com>.
Can you check your select query to run on non partitioned tables. Check if
it's giving correct values.

Same as for dept. B
 On Nov 17, 2014 10:03 AM, "unmesha sreeveni" <un...@gmail.com> wrote:

> ***I created a Hive table with *non*- *partitioned* and using select
> query I inserted data into *Partioned* Hive table.
>
> On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
> wrote:
>
>> I created a Hive table with *partition* and inserted data into Partioned
>> Hive table.
>>
>> Refered site
>> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>>
>>    1.
>>
>>    *Initially created one Non -partioned table and then using select
>>    query and loaded data into partioned table. Is there an alternate way?*
>>    2.
>>
>>    *By following above link my partioned table contains duplicate
>>    values. Below are the setps*
>>
>> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>>
>> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>>
>> But after updating a value in Hive table,the values are getting
>> duplicated.
>>
>> 7       Nirmal  Tech    12000   A
>> 7       Nirmal  Tech    12000   B
>>
>> Nirmal is placed in Department *A* only
>> ​,​
>> but it is duplicated to department *B*.
>>
>> And Once I update a column value in middle I am getting NULL values
>> displayed,while updating last column it is fine.
>>
>> Am I doing any thing wrong.
>> Please suggest.--
>> *Thanks & Regards *
>>
>>
>> *Unmesha Sreeveni U.B*
>> *Hadoop, Bigdata Developer*
>> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
>> http://www.unmeshasreeveni.blogspot.in/
>>
>>
>>
>
>
> --
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>

Re: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
***I created a Hive table with *non*- *partitioned* and using select query
I inserted data into *Partioned* Hive table.

On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
wrote:

> I created a Hive table with *partition* and inserted data into Partioned
> Hive table.
>
> Refered site
> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>
>    1.
>
>    *Initially created one Non -partioned table and then using select
>    query and loaded data into partioned table. Is there an alternate way?*
>    2.
>
>    *By following above link my partioned table contains duplicate values.
>    Below are the setps*
>
> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>
> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>
> But after updating a value in Hive table,the values are getting duplicated.
>
> 7       Nirmal  Tech    12000   A
> 7       Nirmal  Tech    12000   B
>
> Nirmal is placed in Department *A* only
> ​,​
> but it is duplicated to department *B*.
>
> And Once I update a column value in middle I am getting NULL values
> displayed,while updating last column it is fine.
>
> Am I doing any thing wrong.
> Please suggest.--
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>


-- 
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Re: Values getting duplicated in Hive table(Partitioned)

Posted by hadoop hive <ha...@gmail.com>.
You need to check you query. Last one is. Column and data is replicated by
your query only.
On Nov 17, 2014 10:01 AM, "unmesha sreeveni" <un...@gmail.com> wrote:

> I created a Hive table with *partition* and inserted data into Partioned
> Hive table.
>
> Refered site
> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>
>    1.
>
>    *Initially created one Non -partioned table and then using select
>    query and loaded data into partioned table. Is there an alternate way?*
>    2.
>
>    *By following above link my partioned table contains duplicate values.
>    Below are the setps*
>
> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>
> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>
> But after updating a value in Hive table,the values are getting duplicated.
>
> 7       Nirmal  Tech    12000   A
> 7       Nirmal  Tech    12000   B
>
> Nirmal is placed in Department *A* only
> ​,​
> but it is duplicated to department *B*.
>
> And Once I update a column value in middle I am getting NULL values
> displayed,while updating last column it is fine.
>
> Am I doing any thing wrong.
> Please suggest.--
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>

Re: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
***I created a Hive table with *non*- *partitioned* and using select query
I inserted data into *Partioned* Hive table.

On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
wrote:

> I created a Hive table with *partition* and inserted data into Partioned
> Hive table.
>
> Refered site
> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>
>    1.
>
>    *Initially created one Non -partioned table and then using select
>    query and loaded data into partioned table. Is there an alternate way?*
>    2.
>
>    *By following above link my partioned table contains duplicate values.
>    Below are the setps*
>
> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>
> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>
> But after updating a value in Hive table,the values are getting duplicated.
>
> 7       Nirmal  Tech    12000   A
> 7       Nirmal  Tech    12000   B
>
> Nirmal is placed in Department *A* only
> ​,​
> but it is duplicated to department *B*.
>
> And Once I update a column value in middle I am getting NULL values
> displayed,while updating last column it is fine.
>
> Am I doing any thing wrong.
> Please suggest.--
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>


-- 
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Re: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
***I created a Hive table with *non*- *partitioned* and using select query
I inserted data into *Partioned* Hive table.

On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
wrote:

> I created a Hive table with *partition* and inserted data into Partioned
> Hive table.
>
> Refered site
> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>
>    1.
>
>    *Initially created one Non -partioned table and then using select
>    query and loaded data into partioned table. Is there an alternate way?*
>    2.
>
>    *By following above link my partioned table contains duplicate values.
>    Below are the setps*
>
> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>
> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>
> But after updating a value in Hive table,the values are getting duplicated.
>
> 7       Nirmal  Tech    12000   A
> 7       Nirmal  Tech    12000   B
>
> Nirmal is placed in Department *A* only
> ​,​
> but it is duplicated to department *B*.
>
> And Once I update a column value in middle I am getting NULL values
> displayed,while updating last column it is fine.
>
> Am I doing any thing wrong.
> Please suggest.--
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>


-- 
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Re: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
***I created a Hive table with *non*- *partitioned* and using select query
I inserted data into *Partioned* Hive table.

On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
wrote:

> I created a Hive table with *partition* and inserted data into Partioned
> Hive table.
>
> Refered site
> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>
>    1.
>
>    *Initially created one Non -partioned table and then using select
>    query and loaded data into partioned table. Is there an alternate way?*
>    2.
>
>    *By following above link my partioned table contains duplicate values.
>    Below are the setps*
>
> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>
> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>
> But after updating a value in Hive table,the values are getting duplicated.
>
> 7       Nirmal  Tech    12000   A
> 7       Nirmal  Tech    12000   B
>
> Nirmal is placed in Department *A* only
> ​,​
> but it is duplicated to department *B*.
>
> And Once I update a column value in middle I am getting NULL values
> displayed,while updating last column it is fine.
>
> Am I doing any thing wrong.
> Please suggest.--
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>


-- 
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/

Re: Values getting duplicated in Hive table(Partitioned)

Posted by unmesha sreeveni <un...@gmail.com>.
***I created a Hive table with *non*- *partitioned* and using select query
I inserted data into *Partioned* Hive table.

On Mon, Nov 17, 2014 at 10:00 AM, unmesha sreeveni <un...@gmail.com>
wrote:

> I created a Hive table with *partition* and inserted data into Partioned
> Hive table.
>
> Refered site
> <https://blog.safaribooksonline.com/2012/12/03/tip-partitioning-data-in-hive/>
>
>    1.
>
>    *Initially created one Non -partioned table and then using select
>    query and loaded data into partioned table. Is there an alternate way?*
>    2.
>
>    *By following above link my partioned table contains duplicate values.
>    Below are the setps*
>
> This is my Sample employee dataset:link1 <http://pastebin.com/tVh16Yxt>
>
> I tried the following queries: link2 <http://pastebin.com/U2yykWpy>
>
> But after updating a value in Hive table,the values are getting duplicated.
>
> 7       Nirmal  Tech    12000   A
> 7       Nirmal  Tech    12000   B
>
> Nirmal is placed in Department *A* only
> ​,​
> but it is duplicated to department *B*.
>
> And Once I update a column value in middle I am getting NULL values
> displayed,while updating last column it is fine.
>
> Am I doing any thing wrong.
> Please suggest.--
> *Thanks & Regards *
>
>
> *Unmesha Sreeveni U.B*
> *Hadoop, Bigdata Developer*
> *Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
> http://www.unmeshasreeveni.blogspot.in/
>
>
>


-- 
*Thanks & Regards *


*Unmesha Sreeveni U.B*
*Hadoop, Bigdata Developer*
*Centre for Cyber Security | Amrita Vishwa Vidyapeetham*
http://www.unmeshasreeveni.blogspot.in/