Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Won't Fix
-
2.0.1
-
None
-
None
-
CarbonData 2.0.1 with Spark 2.4.5
Description
Hi ,
I am facing issues with materialized views - the query is not hitting the view in the explain plan .I would really appreciate if you could help me on this.
Below are the details :
I am using Spark shell to connect to Carbon 2.0.1 using spark 2.4.5
Underlying table has data loaded.
I think problem is while create materialized view as i am getting a error related to metastore.
scala> carbon.sql("create MATERIALIZED VIEW agg_sales_mv as select country, sex,sum(quantity),avg(price) from sales group by country,sex").show()
20/08/26 01:04:41 AUDIT audit: {"time":"August 26, 2020 1:04:41 AM IST","username":"root","opName":"CREATE MATERIALIZED VIEW","opId":"16462372696035311","opStatus":"START"}
20/08/26 01:04:45 AUDIT audit: {"time":"August 26, 2020 1:04:45 AM IST","username":"root","opName":"CREATE TABLE","opId":"16462377160819798","opStatus":"START"}
20/08/26 01:04:46 AUDIT audit: {"time":"August 26, 2020 1:04:46 AM IST","username":"root","opName":"CREATE TABLE","opId":"16462377696791275","opStatus":"START"}
20/08/26 01:04:48 AUDIT audit: {"time":"August 26, 2020 1:04:48 AM IST","username":"root","opName":"CREATE TABLE","opId":"16462377696791275","opStatus":"SUCCESS","opTime":"2326 ms","table":"NA","extraInfo":{}}
20/08/26 01:04:48 AUDIT audit: {"time":"August 26, 2020 1:04:48 AM IST","username":"root","opName":"CREATE TABLE","opId":"16462377160819798","opStatus":"SUCCESS","opTime":"2955 ms","table":"default.agg_sales_mv","extraInfo":{"local_dictionary_threshold":"10000","bad_record_path":"","table_blocksize":"1024","local_dictionary_enable":"true","flat_folder":"false","external":"false","sort_columns":"","comment":"","carbon.column.compressor":"snappy","mv_related_tables":"sales"}}
20/08/26 01:04:50 ERROR CarbonInternalMetastore$: Adding/Modifying tableProperties operation failed: org.apache.spark.sql.hive.HiveExternalCatalog cannot be cast to org.apache.spark.sql.catalyst.catalog.ExternalCatalogWithListener
20/08/26 01:04:50 ERROR CarbonInternalMetastore$: Adding/Modifying tableProperties operation failed: org.apache.spark.sql.hive.HiveExternalCatalog cannot be cast to org.apache.spark.sql.catalyst.catalog.ExternalCatalogWithListener
20/08/26 01:04:51 AUDIT audit: {"time":"August 26, 2020 1:04:51 AM IST","username":"root","opName":"CREATE MATERIALIZED VIEW","opId":"16462372696035311","opStatus":"SUCCESS","opTime":"10551 ms","table":"NA","extraInfo":{"mvName":"agg_sales_mv"}}
++
++
++