Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Won't Fix
-
1.3.0
-
None
Description
It success:
test("test timeseries create table 18: support day=1,year=1,month=1") { try { sql( """create datamap agg1 on table mainTable | using 'preaggregate' | DMPROPERTIES ( | 'timeseries.eventTime'='dataTime', | 'timeseries.hierarchy'='day=1,year=1,month=1') | as select dataTime, sum(age) from mainTable | group by dataTime """.stripMargin) checkExistence(sql("show tables"), false, "maintable_agg1_hour") checkExistence(sql("show tables"), true, "maintable_agg1_day", "maintable_agg1_month", "maintable_agg1_year") } catch { case _: Exception => assert(false) } }
but it fail:
test("test timeseries create table 21: don't support year=1,month=1") { try { sql( """create datamap agg1 on table mainTable |using 'preaggregate' |DMPROPERTIES ( | 'timeseries.eventTime'='dataTime', | 'timeseries.hierarchy'='year=1,month=1') |as select dataTime, sum(age) from mainTable |group by dataTime""".stripMargin) assert(false) } catch { case e: MalformedCarbonCommandException => assert(e.getMessage.contains("year=1,month=1 is in wrong order")) } finally { checkExistence(sql("show tables"), false, "maintable_agg1_year") } }