qiuchenjian commented on a change in pull request #3229: [HOTFIX] Fixed count(*) issue when MV is created with simple projection.
URL:
https://github.com/apache/carbondata/pull/3229#discussion_r285994269
##########
File path: datamap/mv/core/src/test/scala/org/apache/carbondata/mv/rewrite/MVCreateTestCase.scala
##########
@@ -1019,6 +1019,17 @@ class MVCreateTestCase extends QueryTest with BeforeAndAfterAll {
sql("drop table if exists all_table")
}
+ test("count test case") {
+
+ sql("drop table if exists mvtable1")
+ sql("create table mvtable1(name string,age int,salary int) stored by 'carbondata'")
+ sql("create datamap MV11 using 'mv' as select name from mvtable1")
+ sql(" insert into mvtable1 select 'n1',12,12")
+ sql("rebuild datamap MV11")
+ checkAnswer(sql("select count(*) from mvtable1"),Seq(Row(1)))
Review comment:
better to check if use MV through ```verifyMVDataMap```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[hidden email]
With regards,
Apache Git Services