You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by CHEBARO Abdallah <Ab...@murex.com> on 2014/07/31 12:14:04 UTC

Input

Hello,

I am using Hive and trying to read from a txt file.

I have an input like the following: "string";"string";"integer".

First, I specified that the row fields are delimited by a semi-column. Is it possible to read the integer without the quotations?

Thank you
*******************************

This e-mail contains information for the intended recipient only. It may contain proprietary material or confidential information. If you are not the intended recipient you are not authorised to distribute, copy or use this e-mail or any attachment to it. Murex cannot guarantee that it is virus free and accepts no responsibility for any loss or damage arising from its use. If you have received this e-mail in error please notify immediately the sender and delete the original email received, any attachments and all copies from your system.

Re: Input

Posted by Bala Krishna Gangisetty <ba...@altiscale.com>.
Typo:

> You might want to write a custom **UDF** with a simple logic to convert
string to integer.

--Bala G.


On Thu, Jul 31, 2014 at 12:12 PM, Bala Krishna Gangisetty <
bala@altiscale.com> wrote:

> You might want to write a custom SerDe with a simple logic to convert
> string to integer.
>
> --Bala G.
>
>
> On Thu, Jul 31, 2014 at 3:29 AM, CHEBARO Abdallah <
> Abdallah.CHEBARO@murex.com> wrote:
>
>>  I know it will be a complete string. I am trying to “integer” without
>> the quotations.
>>
>>
>>
>> *From:* Nitin Pawar [mailto:nitinpawar432@gmail.com]
>> *Sent:* Thursday, July 31, 2014 1:28 PM
>> *To:* user@hive.apache.org
>> *Subject:* Re: Input
>>
>>
>>
>> if you specified ; as your delimiter then "abc" will be complete string
>> and not abc only.
>>
>>
>>
>> Take a look at csv fileformat if you want to use proper comma delimited
>> feature
>>
>>
>>
>> On Thu, Jul 31, 2014 at 3:44 PM, CHEBARO Abdallah <
>> Abdallah.CHEBARO@murex.com> wrote:
>>
>> Hello,
>>
>>
>>
>> I am using Hive and trying to read from a txt file.
>>
>>
>>
>> I have an input like the following: “string”;”string”;”integer”.
>>
>>
>>
>> First, I specified that the row fields are delimited by a semi-column. Is
>> it possible to read the integer without the quotations?
>>
>>
>>
>> Thank you
>>
>> *******************************
>>
>> This e-mail contains information for the intended recipient only. It may
>> contain proprietary material or confidential information. If you are not
>> the intended recipient you are not authorised to distribute, copy or use
>> this e-mail or any attachment to it. Murex cannot guarantee that it is
>> virus free and accepts no responsibility for any loss or damage arising
>> from its use. If you have received this e-mail in error please notify
>> immediately the sender and delete the original email received, any
>> attachments and all copies from your system.
>>
>>
>>
>>
>>
>> --
>> Nitin Pawar
>>
>> *******************************
>>
>> This e-mail contains information for the intended recipient only. It may
>> contain proprietary material or confidential information. If you are not
>> the intended recipient you are not authorised to distribute, copy or use
>> this e-mail or any attachment to it. Murex cannot guarantee that it is
>> virus free and accepts no responsibility for any loss or damage arising
>> from its use. If you have received this e-mail in error please notify
>> immediately the sender and delete the original email received, any
>> attachments and all copies from your system.
>>
>
>

Re: Input

Posted by Bala Krishna Gangisetty <ba...@altiscale.com>.
You might want to write a custom SerDe with a simple logic to convert
string to integer.

--Bala G.


On Thu, Jul 31, 2014 at 3:29 AM, CHEBARO Abdallah <
Abdallah.CHEBARO@murex.com> wrote:

>  I know it will be a complete string. I am trying to “integer” without
> the quotations.
>
>
>
> *From:* Nitin Pawar [mailto:nitinpawar432@gmail.com]
> *Sent:* Thursday, July 31, 2014 1:28 PM
> *To:* user@hive.apache.org
> *Subject:* Re: Input
>
>
>
> if you specified ; as your delimiter then "abc" will be complete string
> and not abc only.
>
>
>
> Take a look at csv fileformat if you want to use proper comma delimited
> feature
>
>
>
> On Thu, Jul 31, 2014 at 3:44 PM, CHEBARO Abdallah <
> Abdallah.CHEBARO@murex.com> wrote:
>
> Hello,
>
>
>
> I am using Hive and trying to read from a txt file.
>
>
>
> I have an input like the following: “string”;”string”;”integer”.
>
>
>
> First, I specified that the row fields are delimited by a semi-column. Is
> it possible to read the integer without the quotations?
>
>
>
> Thank you
>
> *******************************
>
> This e-mail contains information for the intended recipient only. It may
> contain proprietary material or confidential information. If you are not
> the intended recipient you are not authorised to distribute, copy or use
> this e-mail or any attachment to it. Murex cannot guarantee that it is
> virus free and accepts no responsibility for any loss or damage arising
> from its use. If you have received this e-mail in error please notify
> immediately the sender and delete the original email received, any
> attachments and all copies from your system.
>
>
>
>
>
> --
> Nitin Pawar
>
> *******************************
>
> This e-mail contains information for the intended recipient only. It may
> contain proprietary material or confidential information. If you are not
> the intended recipient you are not authorised to distribute, copy or use
> this e-mail or any attachment to it. Murex cannot guarantee that it is
> virus free and accepts no responsibility for any loss or damage arising
> from its use. If you have received this e-mail in error please notify
> immediately the sender and delete the original email received, any
> attachments and all copies from your system.
>

RE: Input

Posted by CHEBARO Abdallah <Ab...@murex.com>.
I know it will be a complete string. I am trying to “integer” without the quotations.

From: Nitin Pawar [mailto:nitinpawar432@gmail.com]
Sent: Thursday, July 31, 2014 1:28 PM
To: user@hive.apache.org
Subject: Re: Input

if you specified ; as your delimiter then "abc" will be complete string and not abc only.

Take a look at csv fileformat if you want to use proper comma delimited feature

On Thu, Jul 31, 2014 at 3:44 PM, CHEBARO Abdallah <Ab...@murex.com>> wrote:
Hello,

I am using Hive and trying to read from a txt file.

I have an input like the following: “string”;”string”;”integer”.

First, I specified that the row fields are delimited by a semi-column. Is it possible to read the integer without the quotations?

Thank you

*******************************

This e-mail contains information for the intended recipient only. It may contain proprietary material or confidential information. If you are not the intended recipient you are not authorised to distribute, copy or use this e-mail or any attachment to it. Murex cannot guarantee that it is virus free and accepts no responsibility for any loss or damage arising from its use. If you have received this e-mail in error please notify immediately the sender and delete the original email received, any attachments and all copies from your system.



--
Nitin Pawar
*******************************

This e-mail contains information for the intended recipient only. It may contain proprietary material or confidential information. If you are not the intended recipient you are not authorised to distribute, copy or use this e-mail or any attachment to it. Murex cannot guarantee that it is virus free and accepts no responsibility for any loss or damage arising from its use. If you have received this e-mail in error please notify immediately the sender and delete the original email received, any attachments and all copies from your system.

Re: Input

Posted by Nitin Pawar <ni...@gmail.com>.
if you specified ; as your delimiter then "abc" will be complete string and
not abc only.

Take a look at csv fileformat if you want to use proper comma delimited
feature


On Thu, Jul 31, 2014 at 3:44 PM, CHEBARO Abdallah <
Abdallah.CHEBARO@murex.com> wrote:

>  Hello,
>
>
>
> I am using Hive and trying to read from a txt file.
>
>
>
> I have an input like the following: “string”;”string”;”integer”.
>
>
>
> First, I specified that the row fields are delimited by a semi-column. Is
> it possible to read the integer without the quotations?
>
>
>
> Thank you
>
> *******************************
>
> This e-mail contains information for the intended recipient only. It may
> contain proprietary material or confidential information. If you are not
> the intended recipient you are not authorised to distribute, copy or use
> this e-mail or any attachment to it. Murex cannot guarantee that it is
> virus free and accepts no responsibility for any loss or damage arising
> from its use. If you have received this e-mail in error please notify
> immediately the sender and delete the original email received, any
> attachments and all copies from your system.
>



-- 
Nitin Pawar