You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@carbondata.apache.org by "Vandana Yadav (JIRA)" <ji...@apache.org> on 2018/07/31 12:44:00 UTC

[jira] [Commented] (CARBONDATA-1003) Inaccurate result displays while using covar_pop and covar_samp aggregate functions in presto integration

    [ https://issues.apache.org/jira/browse/CARBONDATA-1003?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16563606#comment-16563606 ] 

Vandana Yadav commented on CARBONDATA-1003:
-------------------------------------------

carbondata-presto connector is not responsible for computing aggregate functions as all the computing is performed by presto itself, that's why closing this bug

> Inaccurate result displays while using covar_pop and  covar_samp aggregate functions in presto integration
> ----------------------------------------------------------------------------------------------------------
>
>                 Key: CARBONDATA-1003
>                 URL: https://issues.apache.org/jira/browse/CARBONDATA-1003
>             Project: CarbonData
>          Issue Type: Improvement
>          Components: data-query, presto-integration
>    Affects Versions: 1.1.0
>         Environment: spark 2.1,presto 0.166
>            Reporter: Vandana Yadav
>            Priority: Minor
>         Attachments: 2000_UniqData.csv
>
>
> Inaccurate result displays while using covar_pop and  covar_samp aggregate functions in presto integration..
> Steps to reproduce :
> 1. In CarbonData:
> a) Create table:
> CREATE TABLE uniqdata (CUST_ID int,CUST_NAME String,ACTIVE_EMUI_VERSION string, DOB timestamp, DOJ timestamp, BIGINT_COLUMN1 bigint,BIGINT_COLUMN2 bigint,DECIMAL_COLUMN1 decimal(30,10), DECIMAL_COLUMN2 decimal(36,10),Double_COLUMN1 double, Double_COLUMN2 double,INTEGER_COLUMN1 int) STORED BY 'org.apache.carbondata.format' TBLPROPERTIES ("TABLE_BLOCKSIZE"= "256 MB");
> b) Load data : 
> LOAD DATA INPATH 'hdfs://localhost:54310/2000_UniqData.csv' into table uniqdata OPTIONS('DELIMITER'=',' , 'QUOTECHAR'='"','BAD_RECORDS_ACTION'='FORCE','FILEHEADER'='CUST_ID,CUST_NAME,ACTIVE_EMUI_VERSION,DOB,DOJ,BIGINT_COLUMN1,BIGINT_COLUMN2,DECIMAL_COLUMN1,DECIMAL_COLUMN2,Double_COLUMN1,Double_COLUMN2,INTEGER_COLUMN1');
> 2. In presto 
>  Execute the query: 
> 1.) select covar_pop(BIGINT_COLUMN1,BIGINT_COLUMN1) as a  from (select BIGINT_COLUMN1 from uniqdata order by BIGINT_COLUMN1) t
> Actual result:
> In CarbonData :
> "+-----------------------+--+
> |           a           |
> +-----------------------+--+
> | 6.158207330830757E20  |
> +-----------------------+--+
> 1 row selected (0.86 seconds)"
> In presto:
> "     a      
> -------------
>  6.158207E20 
> (1 row)
> Query 20170419_063811_00020_khh7w, FINISHED, 1 node
> Splits: 35 total, 35 done (100.00%)
> 0:00 [2.01K rows, 1.97KB] [8.39K rows/s, 8.21KB/s]"
> 2.)select covar_samp(BIGINT_COLUMN1,BIGINT_COLUMN1) as a  from (select BIGINT_COLUMN1 from uniqdata order by BIGINT_COLUMN1) t
> Actual result:
> In CarbonData:
> "+-----------------------+--+
> |           a           |
> +-----------------------+--+
> | 6.161286434496173E20  |
> +-----------------------+--+
> 1 row selected (0.764 seconds)"
> In presto:
> "      a      
> -------------
>  6.161286E20 
> (1 row)
> Query 20170419_070158_00021_khh7w, FINISHED, 1 node
> Splits: 35 total, 35 done (100.00%)
> 0:00 [2.01K rows, 1.97KB] [7.09K rows/s, 6.94KB/s]"
> Expected result :it should display the same result as showing in CarbonData.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)