You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@carbondata.apache.org by "Babulal (JIRA)" <ji...@apache.org> on 2018/07/13 15:58:00 UTC
[jira] [Created] (CARBONDATA-2742) [MV] Wrong data displayed after
MV creation.
Babulal created CARBONDATA-2742:
-----------------------------------
Summary: [MV] Wrong data displayed after MV creation.
Key: CARBONDATA-2742
URL: https://issues.apache.org/jira/browse/CARBONDATA-2742
Project: CarbonData
Issue Type: Bug
Reporter: Babulal
0: jdbc:hive2://10.18.16.173:23040/default> create table mytest_48 (rownumber int,name string, m1 int) stored by 'carbondata';
+---------+--+
| Result |
+---------+--+
+---------+--+
No rows selected (1.267 seconds)
0: jdbc:hive2://10.18.16.173:23040/default> load data inpath 'hdfs://hacluster/tmp/babu/testdata_1.csv' into table mytest_48 ;
+---------+--+
| Result |
+---------+--+
+---------+–+
0: jdbc:hive2://10.18.16.173:23040/default> show datamap on table mytest_48;
+--------------+------------+-------------------+---------------------+--+
| DataMapName | ClassName | Associated Table | DataMap Properties |
+--------------+------------+-------------------+---------------------+--+
+--------------+------------+-------------------+---------------------+--+
No rows selected (0.162 seconds)
0: jdbc:hive2://10.18.16.173:23040/default>
0: jdbc:hive2://10.18.16.173:23040/default> select * from mytest_48;
+------------+-------+----------+--+
| rownumber | name | m1 |
+------------+-------+----------+--+
| 1 | aaa | 1000 |
| 2 | aaa | 65000 |
| 3 | aaa | 1000000 |
| 1 | ddd | 1000 |
| 2 | ddd | 65000 |
| 3 | ddd | 1000000 |
+------------+-------+----------+--+
6 rows selected (1.266 seconds)
0: jdbc:hive2://10.18.16.173:23040/default> create datamap map9 using 'mv' as select sum(m1),name from mytest_48 group by name;
+---------+--+
| Result |
+---------+--+
+---------+--+
No rows selected (0.82 seconds)
0: jdbc:hive2://10.18.16.173:23040/default> select sum(m1),name from mytest_48 group by name;
+----------+-------+--+
| sum(m1) | name |
+----------+-------+--+
+----------+-------+--+
No rows selected (2.615 seconds)
0: jdbc:hive2://10.18.16.173:23040/default> explain select sum(m1),name from mytest_48 group by name;
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--+
| plan |
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--+
| == CarbonData Profiler ==
|
| == Physical Plan ==
*HashAggregate(keys=[mytest_48_name#297], functions=[sum(sum_m1#296L)])
+- Exchange hashpartitioning(mytest_48_name#297, 200)
+- *HashAggregate(keys=[mytest_48_name#297], functions=[partial_sum(sum_m1#296L)])
+- *BatchedScan CarbonDatasourceHadoopRelation [ Database name :babu, Table name :map9_table, Schema :Some(StructType(StructField(sum_m1,LongType,true), StructField(mytest_48_name,StringType,true))) ] babu.map9_table[sum_m1#296L,mytest_48_name#297] |
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+–+
Data in CSV
rownumber,name,m1
1,aaa,1000
2,aaa,65000
3,aaa,1000000
1,ddd,1000
2,ddd,65000
3,ddd,1000000
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)