Why INT type is stored like BIGINT?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Why INT type is stored like BIGINT?

cenyuhai
Hi, all:
    I find that INT is is stored like BIGINT? Why?
Reply | Threaded
Open this post in threaded view
|

Re: Why INT type is stored like BIGINT?

ravipesala
Hi,

Since we use delta compression for measure types in carbondata , it stores
the data with least datatype as per the values in blocklet. So it does not
matter whether we store INT or BIGINT in carbondata files, it always use
least datatype to store.

Regards,
Ravi

On 4 December 2016 at 13:28, Sea <[hidden email]> wrote:

> Hi, all:
>     I find that INT is is stored like BIGINT? Why?




--
Thanks & Regards,
Ravi
Reply | Threaded
Open this post in threaded view
|

Re: Why INT type is stored like BIGINT?

Jacky Li
Hi,

As Ravindra explained, when writing to file, INT is stored using least datatype adaptively according to the actual data in the column chunk, it could be byte, or short, or int. But during decoding and encoding, it does use long (bigint) as  temporary structure. I am working on a patch to optimize this part.

Regards,
Jacky

> 在 2016年12月5日,上午1:43,Ravindra Pesala <[hidden email]> 写道:
>
> Hi,
>
> Since we use delta compression for measure types in carbondata , it stores
> the data with least datatype as per the values in blocklet. So it does not
> matter whether we store INT or BIGINT in carbondata files, it always use
> least datatype to store.
>
> Regards,
> Ravi
>
> On 4 December 2016 at 13:28, Sea <[hidden email]> wrote:
>
>> Hi, all:
>>    I find that INT is is stored like BIGINT? Why?
>
>
>
>
> --
> Thanks & Regards,
> Ravi