carbondata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ravipes...@apache.org
Subject [1/3] incubator-carbondata git commit: resolved merge conflict from master
Date Mon, 12 Dec 2016 04:50:17 GMT
Repository: incubator-carbondata
Updated Branches:
  refs/heads/master 05c02ef0e -> 0cbb32586


http://git-wip-us.apache.org/repos/asf/incubator-carbondata/blob/8e036486/integration-testcases/src/test/scala/org/apache/spark/testsuite/allqueries/AllDataTypesTestCase1.scala
----------------------------------------------------------------------
diff --git a/integration-testcases/src/test/scala/org/apache/spark/testsuite/allqueries/AllDataTypesTestCase1.scala b/integration-testcases/src/test/scala/org/apache/spark/testsuite/allqueries/AllDataTypesTestCase1.scala
index a16a85c..613ee5e 100644
--- a/integration-testcases/src/test/scala/org/apache/spark/testsuite/allqueries/AllDataTypesTestCase1.scala
+++ b/integration-testcases/src/test/scala/org/apache/spark/testsuite/allqueries/AllDataTypesTestCase1.scala
@@ -22,121 +22,138 @@ package org.apache.carbondata.spark.testsuite.allqueries
 
 import java.io.File
 
-import org.apache.spark.sql.Row
+import org.apache.carbondata.core.constants.CarbonCommonConstants
+import org.apache.carbondata.core.util.CarbonProperties
 import org.apache.spark.sql.common.util.CarbonHiveContext._
 import org.apache.spark.sql.common.util.QueryTest
-import org.apache.carbondata.core.util.CarbonProperties
 import org.scalatest.BeforeAndAfterAll
 
 /**
- * Test Class for all queries on multiple datatypes
- * Manohar
- */
+  * Test Class for all queries on multiple datatypes
+  * Manohar
+  */
 class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
 
   override def beforeAll {
 
     val currentDirectory = new File(this.getClass.getResource("/").getPath + "/../../")
       .getCanonicalPath
+
     CarbonProperties.getInstance().addProperty("carbon.direct.surrogate", "false")
     try {
       sql(
         "create table Carbon_automation_test (imei string,deviceInformationId int,MAC string," +
-        "deviceColor string,device_backColor string,modelId string,marketName string,AMSize " +
-        "string,ROMSize string,CUPAudit string,CPIClocked string,series string,productionDate " +
-        "string,bomCode string,internalModels string, deliveryTime string, channelsId string, " +
-        "channelsName string , deliveryAreaId string, deliveryCountry string, deliveryProvince " +
-        "string, deliveryCity string,deliveryDistrict string, deliveryStreet string, " +
-        "oxSingleNumber string, ActiveCheckTime string, ActiveAreaId string, ActiveCountry " +
-        "string, ActiveProvince string, Activecity string, ActiveDistrict string, ActiveStreet " +
-        "string, ActiveOperatorId string, Active_releaseId string, Active_EMUIVersion string, " +
-        "Active_operaSysVersion string, Active_BacVerNumber string, Active_BacFlashVer string, " +
-        "Active_webUIVersion string, Active_webUITypeCarrVer string,Active_webTypeDataVerNumber " +
-        "string, Active_operatorsVersion string, Active_phonePADPartitionedVersions string, " +
-        "Latest_YEAR int, Latest_MONTH int, Latest_DAY int, Latest_HOUR string, Latest_areaId " +
-        "string, Latest_country string, Latest_province string, Latest_city string, " +
-        "Latest_district string, Latest_street string, Latest_releaseId string, " +
-        "Latest_EMUIVersion string, Latest_operaSysVersion string, Latest_BacVerNumber string, " +
-        "Latest_BacFlashVer string, Latest_webUIVersion string, Latest_webUITypeCarrVer string, " +
-        "Latest_webTypeDataVerNumber string, Latest_operatorsVersion string, " +
-        "Latest_phonePADPartitionedVersions string, Latest_operatorId string, " +
-        "gamePointDescription string, gamePointId int,contractNumber int) stored by 'org.apache" +
-        ".carbondata.format' TBLPROPERTIES('DICTIONARY_EXCLUDE'='Latest_DAY,deviceInformationId," +
-        "Latest_MONTH')")
+          "deviceColor string,device_backColor string,modelId string,marketName string,AMSize " +
+          "string,ROMSize string,CUPAudit string,CPIClocked string,series string,productionDate " +
+          "string,bomCode string,internalModels string, deliveryTime string, channelsId string, " +
+          "channelsName string , deliveryAreaId string, deliveryCountry string, deliveryProvince " +
+          "string, deliveryCity string,deliveryDistrict string, deliveryStreet string, " +
+          "oxSingleNumber string, ActiveCheckTime string, ActiveAreaId string, ActiveCountry " +
+          "string, ActiveProvince string, Activecity string, ActiveDistrict string, ActiveStreet " +
+          "string, ActiveOperatorId string, Active_releaseId string, Active_EMUIVersion string, " +
+          "Active_operaSysVersion string, Active_BacVerNumber string, Active_BacFlashVer string, " +
+          "Active_webUIVersion string, Active_webUITypeCarrVer string,Active_webTypeDataVerNumber " +
+          "string, Active_operatorsVersion string, Active_phonePADPartitionedVersions string, " +
+          "Latest_YEAR int, Latest_MONTH int, Latest_DAY int, Latest_HOUR string, Latest_areaId " +
+          "string, Latest_country string, Latest_province string, Latest_city string, " +
+          "Latest_district string, Latest_street string, Latest_releaseId string, " +
+          "Latest_EMUIVersion string, Latest_operaSysVersion string, Latest_BacVerNumber string, " +
+          "Latest_BacFlashVer string, Latest_webUIVersion string, Latest_webUITypeCarrVer string, " +
+          "Latest_webTypeDataVerNumber string, Latest_operatorsVersion string, " +
+          "Latest_phonePADPartitionedVersions string, Latest_operatorId string, " +
+          "gamePointDescription string, gamePointId int,contractNumber int) stored by 'org.apache" +
+          ".carbondata.format' TBLPROPERTIES('DICTIONARY_INCLUDE'='Latest_webTypeDataVerNumber')")
+
+      CarbonProperties.getInstance()
+        .addProperty(CarbonCommonConstants.CARBON_TIMESTAMP_FORMAT,
+          CarbonCommonConstants.CARBON_TIMESTAMP_DEFAULT_FORMAT)
+    }
+    catch {
+      case e: Exception => print("ERROR : " + e.getMessage)
+    }
+    try {
       sql("LOAD DATA LOCAL INPATH '" + currentDirectory +
-          "/src/test/resources/100_olap.csv' INTO table Carbon_automation_test OPTIONS" +
-          "('DELIMITER'= ',' ,'QUOTECHAR'= '\"', 'FILEHEADER'= 'imei,deviceInformationId,MAC," +
-          "deviceColor,device_backColor,modelId,marketName,AMSize,ROMSize,CUPAudit,CPIClocked," +
-          "series,productionDate,bomCode,internalModels,deliveryTime,channelsId,channelsName," +
-          "deliveryAreaId,deliveryCountry,deliveryProvince,deliveryCity,deliveryDistrict," +
-          "deliveryStreet,oxSingleNumber,contractNumber,ActiveCheckTime,ActiveAreaId," +
-          "ActiveCountry,ActiveProvince,Activecity,ActiveDistrict,ActiveStreet,ActiveOperatorId," +
-          "Active_releaseId,Active_EMUIVersion,Active_operaSysVersion,Active_BacVerNumber," +
-          "Active_BacFlashVer,Active_webUIVersion,Active_webUITypeCarrVer," +
-          "Active_webTypeDataVerNumber,Active_operatorsVersion," +
-          "Active_phonePADPartitionedVersions,Latest_YEAR,Latest_MONTH,Latest_DAY,Latest_HOUR," +
-          "Latest_areaId,Latest_country,Latest_province,Latest_city,Latest_district," +
-          "Latest_street,Latest_releaseId,Latest_EMUIVersion,Latest_operaSysVersion," +
-          "Latest_BacVerNumber,Latest_BacFlashVer,Latest_webUIVersion,Latest_webUITypeCarrVer," +
-          "Latest_webTypeDataVerNumber,Latest_operatorsVersion," +
-          "Latest_phonePADPartitionedVersions,Latest_operatorId,gamePointId,gamePointDescription')")
-
-
+        "/src/test/resources/100_olap.csv' INTO table Carbon_automation_test OPTIONS" +
+        "('DELIMITER'= ',' ,'QUOTECHAR'= '\"', 'FILEHEADER'= 'imei,deviceInformationId,MAC," +
+        "deviceColor,device_backColor,modelId,marketName,AMSize,ROMSize,CUPAudit,CPIClocked," +
+        "series,productionDate,bomCode,internalModels,deliveryTime,channelsId,channelsName," +
+        "deliveryAreaId,deliveryCountry,deliveryProvince,deliveryCity,deliveryDistrict," +
+        "deliveryStreet,oxSingleNumber,contractNumber,ActiveCheckTime,ActiveAreaId," +
+        "ActiveCountry,ActiveProvince,Activecity,ActiveDistrict,ActiveStreet,ActiveOperatorId," +
+        "Active_releaseId,Active_EMUIVersion,Active_operaSysVersion,Active_BacVerNumber," +
+        "Active_BacFlashVer,Active_webUIVersion,Active_webUITypeCarrVer," +
+        "Active_webTypeDataVerNumber,Active_operatorsVersion," +
+        "Active_phonePADPartitionedVersions,Latest_YEAR,Latest_MONTH,Latest_DAY,Latest_HOUR," +
+        "Latest_areaId,Latest_country,Latest_province,Latest_city,Latest_district," +
+        "Latest_street,Latest_releaseId,Latest_EMUIVersion,Latest_operaSysVersion," +
+        "Latest_BacVerNumber,Latest_BacFlashVer,Latest_webUIVersion,Latest_webUITypeCarrVer," +
+        "Latest_webTypeDataVerNumber,Latest_operatorsVersion," +
+        "Latest_phonePADPartitionedVersions,Latest_operatorId,gamePointId,gamePointDescription')")
+    }
+    catch {
+      case e: Exception => print("ERROR : " + e.getMessage)
+    }
+    try {
       sql(
-        "create table if not exists Carbon_automation_hive (imei string,deviceInformationId int," +
-        "MAC string,deviceColor string,device_backColor string,modelId string,marketName " +
-        "string,AMSize string,ROMSize string,CUPAudit string,CPIClocked string,series string," +
-        "productionDate timestamp,bomCode string,internalModels string, deliveryTime string, " +
-        "channelsId string, channelsName string , deliveryAreaId string, deliveryCountry " +
-        "string, deliveryProvince string, deliveryCity string,deliveryDistrict string, " +
-        "deliveryStreet string, oxSingleNumber string,contractNumber int, ActiveCheckTime string, ActiveAreaId " +
-        "string, ActiveCountry string, ActiveProvince string, Activecity string, ActiveDistrict" +
-        " string, ActiveStreet string, ActiveOperatorId string, Active_releaseId string, " +
-        "Active_EMUIVersion string, Active_operaSysVersion string, Active_BacVerNumber string, " +
-        "Active_BacFlashVer string, Active_webUIVersion string, Active_webUITypeCarrVer string," +
-        "Active_webTypeDataVerNumber string, Active_operatorsVersion string, " +
-        "Active_phonePADPartitionedVersions string, Latest_YEAR int, Latest_MONTH int, " +
-        "Latest_DAY int, Latest_HOUR string, Latest_areaId string, Latest_country string, " +
-        "Latest_province string, Latest_city string, Latest_district string, Latest_street " +
-        "string, Latest_releaseId string, Latest_EMUIVersion string, Latest_operaSysVersion " +
-        "string, Latest_BacVerNumber string, Latest_BacFlashVer string, Latest_webUIVersion " +
-        "string, Latest_webUITypeCarrVer string, Latest_webTypeDataVerNumber string, " +
-        "Latest_operatorsVersion string, Latest_phonePADPartitionedVersions string, " +
-        "Latest_operatorId string, , gamePointId int, gamePointDescription string" +
-        ") row format delimited fields terminated by ','"
+        "create table if not exists Carbon_automation_hive(imei string,deviceInformationId int," +
+          "MAC string,deviceColor string,device_backColor string,modelId string,marketName " +
+          "string,AMSize string,ROMSize string,CUPAudit string,CPIClocked string,series string," +
+          "productionDate timestamp,bomCode string,internalModels string, deliveryTime string, " +
+          "channelsId string, channelsName string , deliveryAreaId string, deliveryCountry " +
+          "string, deliveryProvince string, deliveryCity string,deliveryDistrict string, " +
+          "deliveryStreet string, oxSingleNumber string,contractNumber int, ActiveCheckTime string, ActiveAreaId " +
+          "string, ActiveCountry string, ActiveProvince string, Activecity string, ActiveDistrict" +
+          " string, ActiveStreet string, ActiveOperatorId string, Active_releaseId string, " +
+          "Active_EMUIVersion string, Active_operaSysVersion string, Active_BacVerNumber string, " +
+          "Active_BacFlashVer string, Active_webUIVersion string, Active_webUITypeCarrVer string," +
+          "Active_webTypeDataVerNumber string, Active_operatorsVersion string, " +
+          "Active_phonePADPartitionedVersions string, Latest_YEAR int, Latest_MONTH int, " +
+          "Latest_DAY int, Latest_HOUR string, Latest_areaId string, Latest_country string, " +
+          "Latest_province string, Latest_city string, Latest_district string, Latest_street " +
+          "string, Latest_releaseId string, Latest_EMUIVersion string, Latest_operaSysVersion " +
+          "string, Latest_BacVerNumber string, Latest_BacFlashVer string, Latest_webUIVersion " +
+          "string, Latest_webUITypeCarrVer string, Latest_webTypeDataVerNumber string, " +
+          "Latest_operatorsVersion string, Latest_phonePADPartitionedVersions string, " +
+          "Latest_operatorId string, gamePointId int,gamePointDescription string" +
+          ") row format delimited fields terminated by ','"
       )
-
+    }
+    catch {
+      case e: Exception => print("ERROR : " + e.getMessage)
+    }
+    try {
       sql("LOAD DATA LOCAL INPATH '" + currentDirectory + "/src/test/resources/100_olap.csv' INTO " +
-          "table Carbon_automation_hive ")
+        "table Carbon_automation_hive")
 
-    } catch {
+    }
+    catch {
       case e: Exception => print("ERROR : " + e.getMessage)
     }
+
   }
 
+
   override def afterAll {
-    sql("drop table Carbon_automation_test")
-    sql("drop table Carbon_automation_hive")
+    sql("drop table if exists Carbon_automation_test")
+    sql("drop table if exists Carbon_automation_hive")
 
   }
 
+
   //Test-22
   test(
-    "select channelsId, sum(Latest_DAY+ 10) as a from Carbon_automation_test group by  channelsId"
+    "select channelsId, sum(Latest_MONTH+ 10) as a from Carbon_automation_test group by  channelsId"
   ) {
     checkAnswer(
       sql(
-        "select channelsId, sum(Latest_DAY+ 10) as a from Carbon_automation_test group by  " +
-        "channelsId"
+        "select channelsId, sum(Latest_MONTH+ 10) as a from Carbon_automation_test group by  " +
+          "channelsId"
       ),
-      Seq(Row("1", 132),
-        Row("2", 110),
-        Row("3", 176),
-        Row("4", 132),
-        Row("5", 132),
-        Row("6", 209),
-        Row("7", 198)
+      sql(
+        "select channelsId, sum(Latest_MONTH+ 10) as a from Carbon_automation_hive group by  " +
+          "channelsId"
       )
+
     )
 
   }
@@ -145,201 +162,77 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //Test-24
   test(
     "select channelsId, sum(channelsId+ 10)  Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
+      "channelsId order by Total"
   ) {
     checkAnswer(
       sql(
         "select channelsId, sum(channelsId+ 10)  Total from Carbon_automation_test group by  " +
-        "channelsId order by Total"
+          "channelsId order by Total"
       ),
-      Seq(Row("2", 120),
-        Row("1", 132),
-        Row("4", 168),
-        Row("5", 180),
-        Row("3", 208),
-        Row("6", 304),
-        Row("7", 306)
-      )
-    )
-
-  }
-
-  //Test-25
-  test(
-    "select channelsId, sum(channelsId+channelsId) Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
-  ) {
-    checkAnswer(
       sql(
-        "select channelsId, sum(channelsId+channelsId) Total from Carbon_automation_test group by" +
-        "  channelsId order by Total"
-      ),
-      Seq(Row("1", 24),
-        Row("2", 40),
-        Row("3", 96),
-        Row("4", 96),
-        Row("5", 120),
-        Row("6", 228),
-        Row("7", 252)
+        "select channelsId, sum(channelsId+ 10)  Total from Carbon_automation_hive group by  " +
+          "channelsId order by Total"
       )
-    )
-
-  }
 
-  //Test-26
-  test(
-    "select channelsId, sum(channelsId+channelsId) Total from Carbon_automation_test group by  " +
-    "channelsId"
-  ) {
-    checkAnswer(
-      sql(
-        "select channelsId, sum(channelsId+channelsId) Total from Carbon_automation_test group by" +
-        "  channelsId"
-      ),
-      Seq(Row("1", 24),
-        Row("2", 40),
-        Row("3", 96),
-        Row("4", 96),
-        Row("5", 120),
-        Row("6", 228),
-        Row("7", 252)
-      )
     )
 
   }
-
-  //Test-27
   test(
-    "select channelsId, avg(Latest_DAY+ 10) as a from Carbon_automation_test group by  channelsId"
-  ) {
-    checkAnswer(
-      sql(
-        "select channelsId, avg(Latest_DAY+ 10) as a from Carbon_automation_test group by  " +
-        "channelsId"
-      ),
-      Seq(Row("1", 11),
-        Row("2", 11),
-        Row("3", 11),
-        Row("4", 11),
-        Row("5", 11),
-        Row("6", 11),
-        Row("7", 11)
-      )
-    )
-
-  }
+    "select channelsId, avg(Latest_MONTH+ 10) as a from Carbon_automation_test group by  channelsId"
 
-  //Test-29
-  test(
-    "select channelsId, avg(channelsId+ 10)  Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
   ) {
     checkAnswer(
       sql(
-        "select channelsId, avg(channelsId+ 10)  Total from Carbon_automation_test group by  " +
-        "channelsId order by Total"
+        "select channelsId, avg(Latest_MONTH+ 10) as a from Carbon_automation_test group by  " +
+          "channelsId"
       ),
-      Seq(Row("1", 11),
-        Row("2", 12),
-        Row("3", 13),
-        Row("4", 14),
-        Row("5", 15),
-        Row("6", 16),
-        Row("7", 17)
-      )
-    )
-
-  }
-
-
-  //Test-30
-  test(
-    "select channelsId, avg(channelsId+channelsId) Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
-  ) {
-    checkAnswer(
       sql(
-        "select channelsId, avg(channelsId+channelsId) Total from Carbon_automation_test group by" +
-        "  channelsId order by Total"
-      ),
-      Seq(Row("1", 2),
-        Row("2", 4),
-        Row("3", 6),
-        Row("4", 8),
-        Row("5", 10),
-        Row("6", 12),
-        Row("7", 14)
+        "select channelsId, avg(Latest_MONTH+ 10) as a from Carbon_automation_hive group by  " +
+          "channelsId"
       )
     )
 
   }
 
+
   //Test-31
   test(
+
     "select channelsId, count(Latest_DAY+ 10) as a  from Carbon_automation_test group by  " +
-    "channelsId"
+      "channelsId"
   ) {
     checkAnswer(
       sql(
         "select channelsId, count(Latest_DAY+ 10) as a  from Carbon_automation_test group by  " +
-        "channelsId"
+          "channelsId"
       ),
-      Seq(Row("1", 12),
-        Row("2", 10),
-        Row("3", 16),
-        Row("4", 12),
-        Row("5", 12),
-        Row("6", 19),
-        Row("7", 18)
+      sql(
+        "select channelsId, count(Latest_DAY+ 10) as a  from Carbon_automation_hive group by  " +
+          "channelsId"
       )
     )
-
   }
 
 
   //Test-33
   test(
     "select channelsId, count(channelsId+ 10) Total from Carbon_automation_test group by  " +
-    "channelsId order by channelsId"
+      "channelsId order by channelsId"
   ) {
     checkAnswer(
       sql(
         "select channelsId, count(channelsId+ 10) Total from Carbon_automation_test group by  " +
-        "channelsId order by channelsId"
+          "channelsId order by channelsId"
       ),
-      Seq(Row("1", 12),
-        Row("2", 10),
-        Row("3", 16),
-        Row("4", 12),
-        Row("5", 12),
-        Row("6", 19),
-        Row("7", 18)
+      sql(
+        "select channelsId, count(channelsId+ 10) Total from Carbon_automation_hive group by  " +
+          "channelsId order by channelsId"
       )
     )
 
   }
 
-  //Test-34
-  test(
-    "select channelsId, count(channelsId+channelsId)  Total from Carbon_automation_test group by " +
-    " channelsId order by channelsId"
-  ) {
-    checkAnswer(
-      sql(
-        "select channelsId, count(channelsId+channelsId)  Total from Carbon_automation_test group" +
-        " by  channelsId order by channelsId"
-      ),
-      Seq(Row("1", 12),
-        Row("2", 10),
-        Row("3", 16),
-        Row("4", 12),
-        Row("5", 12),
-        Row("6", 19),
-        Row("7", 18)
-      )
-    )
 
-  }
 
   //Test-35
   test(
@@ -348,15 +241,11 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
     checkAnswer(
       sql(
         "select channelsId, min(Latest_DAY+ 10) as a  from Carbon_automation_test group by  " +
-        "channelsId"
+          "channelsId"
       ),
-      Seq(Row("1", 11),
-        Row("2", 11),
-        Row("3", 11),
-        Row("4", 11),
-        Row("5", 11),
-        Row("6", 11),
-        Row("7", 11)
+      sql(
+        "select channelsId, min(Latest_DAY+ 10) as a  from Carbon_automation_hive group by  " +
+          "channelsId"
       )
     )
 
@@ -366,42 +255,16 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //Test-37
   test(
     "select channelsId, min(channelsId+ 10) Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
+      "channelsId order by Total"
   ) {
     checkAnswer(
       sql(
         "select channelsId, min(channelsId+ 10) Total from Carbon_automation_test group by  " +
-        "channelsId order by Total"
+          "channelsId order by Total"
       ),
-      Seq(Row("1", 11),
-        Row("2", 12),
-        Row("3", 13),
-        Row("4", 14),
-        Row("5", 15),
-        Row("6", 16),
-        Row("7", 17)
-      )
-    )
-
-  }
-
-  //Test-38
-  test(
-    "select channelsId, min(channelsId+channelsId)  Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
-  ) {
-    checkAnswer(
       sql(
-        "select channelsId, min(channelsId+channelsId)  Total from Carbon_automation_test group " +
-        "by  channelsId order by Total"
-      ),
-      Seq(Row("1", 2),
-        Row("2", 4),
-        Row("3", 6),
-        Row("4", 8),
-        Row("5", 10),
-        Row("6", 12),
-        Row("7", 14)
+        "select channelsId, min(channelsId+ 10) Total from Carbon_automation_hive group by  " +
+          "channelsId order by Total"
       )
     )
 
@@ -414,116 +277,44 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
     checkAnswer(
       sql(
         "select channelsId, max(Latest_DAY+ 10) as a  from Carbon_automation_test group by  " +
-        "channelsId"
+          "channelsId"
       ),
-      Seq(Row("1", 11),
-        Row("2", 11),
-        Row("3", 11),
-        Row("4", 11),
-        Row("5", 11),
-        Row("6", 11),
-        Row("7", 11)
-      )
-    )
-
-  }
-
-
-  //Test-41
-  test(
-    "select channelsId, max(channelsId+ 10) Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
-  )({
-
-    checkAnswer(
       sql(
-        "select channelsId, max(channelsId+ 10) Total from Carbon_automation_test group by  " +
-        "channelsId order by Total"
-      ),
-      Seq(Row("1", 11),
-        Row("2", 12),
-        Row("3", 13),
-        Row("4", 14),
-        Row("5", 15),
-        Row("6", 16),
-        Row("7", 17)
+        "select channelsId, max(Latest_DAY+ 10) as a  from Carbon_automation_hive group by  " +
+          "channelsId"
       )
     )
+
   }
-  )
 
-  //Test-42
-  test(
-    "select channelsId, max(channelsId+channelsId)  Total from Carbon_automation_test group by  " +
-    "channelsId order by Total"
-  )({
 
-    checkAnswer(
-      sql(
-        "select channelsId, max(channelsId+channelsId)  Total from Carbon_automation_test group " +
-        "by  channelsId order by Total"
-      ),
-      Seq(Row("1", 2),
-        Row("2", 4),
-        Row("3", 6),
-        Row("4", 8),
-        Row("5", 10),
-        Row("6", 12),
-        Row("7", 14)
-      )
-    )
-  }
-  )
 
   //Test-43
   test(
     "select Latest_YEAR ,sum(distinct Latest_YEAR)+10 from Carbon_automation_test group by " +
-    "Latest_YEAR"
+      "Latest_YEAR"
   )({
 
     checkAnswer(
       sql(
         "select Latest_YEAR ,sum(distinct Latest_YEAR)+10 from Carbon_automation_test group by " +
-        "Latest_YEAR"
-      ),
-      Seq(Row(2015, 2025))
+          "Latest_YEAR"
+      ), sql(
+        "select Latest_YEAR ,sum(distinct Latest_YEAR)+10 from Carbon_automation_hive group by " +
+          "Latest_YEAR"
+      )
     )
   }
   )
 
-  //Test-44
-
-  test(
-    "select Latest_YEAR ,sum(distinct Latest_YEAR)+10 from Carbon_automation_test group by " +
-    "Latest_YEAR."
-  )({
-
-    checkAnswer(
-      sql(
-        "select Latest_YEAR ,sum(distinct Latest_YEAR)+10 from Carbon_automation_test group by " +
-        "Latest_YEAR"
-      ),
-      Seq(Row(2015, 2025))
-    )
-  }
-  )
 
   //Test-47
   test("select sum(gamepointid) +10 as a ,series  from Carbon_automation_test group by series")({
 
     checkAnswer(
       sql("select sum(gamepointid) +10 as a ,series  from Carbon_automation_test group by series"),
-      Seq(Row(12932, "6Series"),
-        Row(25890, "0Series"),
-        Row(12354, "4Series"),
-        Row(13577, "8Series"),
-        Row(18601.197, "7Series"),
-        Row(4011, "1Series"),
-        Row(29081, "5Series"),
-        Row(12930, "9Series"),
-        Row(15245, "3Series"),
-        Row(12364, "2Series")
-      )
+      sql("select sum(gamepointid) +10 as a ,series  from Carbon_automation_hive group by series")
+
     )
   }
   )
@@ -533,108 +324,34 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
 
     checkAnswer(
       sql("select sum(gamepointid) +10.36 as a ,series  from Carbon_automation_test group by " +
-          "series"),
-      Seq(Row(12932.36, "6Series"),
-        Row(25890.36, "0Series"),
-        Row(12354.36, "4Series"),
-        Row(13577.36, "8Series"),
-        Row(18601.557, "7Series"),
-        Row(4011.36, "1Series"),
-        Row(29081.36, "5Series"),
-        Row(12930.36, "9Series"),
-        Row(15245.36, "3Series"),
-        Row(12364.36, "2Series")
-      )
-    )
-  }
-  )
-
-  //TC_055
-  test(
-    "select count(deviceinformationid)+10.32 as a ,series  from Carbon_automation_test group by " +
-    "series"
-  )({
-    checkAnswer(
-      sql(
-        "select count(deviceinformationid)+10.32 as a ,series  from Carbon_automation_test group " +
-        "by series"
-      ),
-      Seq(Row(19.32, "6Series"),
-        Row(25.32, "0Series"),
-        Row(18.32, "4Series"),
-        Row(21.32, "8Series"),
-        Row(21.32, "7Series"),
-        Row(13.32, "1Series"),
-        Row(27.32, "5Series"),
-        Row(18.32, "9Series"),
-        Row(18.32, "3Series"),
-        Row(19.32, "2Series")
-      )
-    )
-  }
-  )
-
-  //TC_056
-  test("select count(gamepointid) +10.36 as a ,series  from Carbon_automation_test group by " +
-       "series")(
-  {
-    checkAnswer(
-      sql(
-        "select count(gamepointid) +10.36 as a ,series  from Carbon_automation_test group by series"
-      ),
-      Seq(Row(19.36, "6Series"),
-        Row(25.36, "0Series"),
-        Row(18.36, "4Series"),
-        Row(21.36, "8Series"),
-        Row(21.36, "7Series"),
-        Row(13.36, "1Series"),
-        Row(27.36, "5Series"),
-        Row(18.36, "9Series"),
-        Row(18.36, "3Series"),
-        Row(19.36, "2Series")
-      )
+        "series"),
+      sql("select sum(gamepointid) +10.36 as a ,series  from Carbon_automation_hive group by " +
+        "series")
     )
   }
   )
 
   //TC_057
   test("select count(latest_year)+10.364 as a,series  from Carbon_automation_test group by series")(
-  {
-    checkAnswer(
-      sql(
-        "select count(latest_year)+10.364 as a,series  from Carbon_automation_test group by series"
-      ),
-      Seq(Row(19.364, "6Series"),
-        Row(25.364, "0Series"),
-        Row(18.364, "4Series"),
-        Row(21.364, "8Series"),
-        Row(21.364, "7Series"),
-        Row(13.364, "1Series"),
-        Row(27.364, "5Series"),
-        Row(18.364, "9Series"),
-        Row(18.364, "3Series"),
-        Row(19.364, "2Series")
+    {
+      checkAnswer(
+        sql(
+          "select count(latest_year)+10.364 as a,series  from Carbon_automation_test group by series"
+        ),
+        sql(
+          "select count(latest_year)+10.364 as a,series  from Carbon_automation_hive group by series"
+        )
       )
-    )
-  }
+    }
   )
 
   //TC_058
   test("select count(distinct series)+10 as a,series from Carbon_automation_test group by series")({
     checkAnswer(
       sql("select count(distinct series)+10 as a,series from Carbon_automation_test group by " +
-          "series"),
-      Seq(Row(11, "6Series"),
-        Row(11, "0Series"),
-        Row(11, "4Series"),
-        Row(11, "8Series"),
-        Row(11, "7Series"),
-        Row(11, "1Series"),
-        Row(11, "5Series"),
-        Row(11, "9Series"),
-        Row(11, "3Series"),
-        Row(11, "2Series")
-      )
+        "series"),
+      sql("select count(distinct series)+10 as a,series from Carbon_automation_hive group by " +
+        "series")
     )
   }
   )
@@ -642,7 +359,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select count(*) as a  from Carbon_automation_test")({
     checkAnswer(
       sql("select count(*) as a  from Carbon_automation_test"),
-      Seq(Row(99))
+      sql("select count(*) as a  from Carbon_automation_hive")
     )
   }
   )
@@ -651,67 +368,37 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("Select count(1) as a  from Carbon_automation_test")({
     checkAnswer(
       sql("Select count(1) as a  from Carbon_automation_test"),
-      Seq(Row(99))
-    )
-  }
-  )
-
-  //TC_062
-  test("select count(imei) as a   from Carbon_automation_test")({
-    checkAnswer(
-      sql("select count(imei) as a   from Carbon_automation_test"),
-      Seq(Row(99))
+      sql("Select count(1) as a  from Carbon_automation_hive")
     )
   }
   )
 
-  //TC_063
-  test("select count(device_backColor)  as a from Carbon_automation_test")({
-    checkAnswer(
-      sql("select count(device_backColor)  as a from Carbon_automation_test"),
-      Seq(Row(99))
-    )
-  }
-  )
 
   //TC_064
   test("select count(DISTINCT imei) as a  from Carbon_automation_test")({
     checkAnswer(
       sql("select count(DISTINCT imei) as a  from Carbon_automation_test"),
-      Seq(Row(99))
+      sql("select count(DISTINCT imei) as a  from Carbon_automation_hive")
     )
   }
   )
 
-  //TC_065
-  test("select count(DISTINCT series) as a from Carbon_automation_test")({
-    checkAnswer(
-      sql("select count(DISTINCT series) as a from Carbon_automation_test"),
-      Seq(Row(10))
-    )
-  }
-  )
 
-  //TC_066
-  test("select count(DISTINCT  device_backColor)  as a from Carbon_automation_test")({
-    checkAnswer(
-      sql("select count(DISTINCT  device_backColor)  as a from Carbon_automation_test"),
-      Seq(Row(10))
-    )
-  }
-  )
 
   //TC_067
   test(
     "select count (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-    "Carbon_automation_test"
+      "Carbon_automation_test"
   )({
     checkAnswer(
       sql(
         "select count (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-        "Carbon_automation_test"
+          "Carbon_automation_test"
       ),
-      Seq(Row(3))
+      sql(
+        "select count (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
+          "Carbon_automation_hive"
+      )
     )
   }
   )
@@ -719,7 +406,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select count(gamePointId)  as a from Carbon_automation_test")({
     checkAnswer(
       sql("select count(gamePointId)  as a from Carbon_automation_test"),
-      Seq(Row(99))
+      sql("select count(gamePointId)  as a from Carbon_automation_hive")
     )
   }
   )
@@ -727,30 +414,25 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select sum(gamePointId) a  from Carbon_automation_test")({
     checkAnswer(
       sql("select sum(gamePointId) a  from Carbon_automation_test"),
-      Seq(Row(156885.197))
-    )
-  }
-  )
-  //TC_077
-  test("select sum(DISTINCT  deviceInformationId) a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select sum(DISTINCT  deviceInformationId) a  from Carbon_automation_test"),
-      Seq(Row(9594717))
+      sql("select sum(gamePointId) a  from Carbon_automation_hive")
     )
   }
   )
+
   //TC_080
   test(
     "select sum (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-    "Carbon_automation_test"
+      "Carbon_automation_test"
   )({
     checkAnswer(
       sql(
         "select sum (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-        "Carbon_automation_test"
+          "Carbon_automation_test"
       ),
-      Seq(Row(111))
-    )
+      sql(
+        "select sum (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
+          "Carbon_automation_hive"
+      ))
   }
   )
 
@@ -758,7 +440,8 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select sum( DISTINCT Latest_MONTH)  a from Carbon_automation_test")({
     checkAnswer(
       sql("select sum( DISTINCT Latest_MONTH)  a from Carbon_automation_test"),
-      Seq(Row(7))
+      sql("select sum( DISTINCT Latest_MONTH)  a from Carbon_automation_hive")
+
     )
   }
   )
@@ -766,14 +449,17 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //TC_088
   test(
     "select avg (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-    "Carbon_automation_test"
+      "Carbon_automation_test"
   )({
     checkAnswer(
       sql(
         "select avg (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-        "Carbon_automation_test"
+          "Carbon_automation_test"
       ),
-      Seq(Row(37.0))
+      sql(
+        "select avg (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
+          "Carbon_automation_hive"
+      )
     )
   }
   )
@@ -781,49 +467,27 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select min(deviceInformationId) a  from Carbon_automation_test")({
     checkAnswer(
       sql("select min(deviceInformationId) a  from Carbon_automation_test"),
-      Seq(Row(1))
-    )
-  }
-  )
-
-  //TC_091
-  test("select min(channelsId) a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select min(channelsId) a  from Carbon_automation_test"),
-      Seq(Row("1"))
+      sql("select min(deviceInformationId) a  from Carbon_automation_hive")
     )
   }
   )
 
-  //TC_092
-  test("select min(bomCode)  a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select min(bomCode)  a  from Carbon_automation_test"),
-      Seq(Row("1"))
-    )
-  }
-  )
 
-  //TC_093
-  test("select min(Latest_MONTH)  a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select min(Latest_MONTH)  a  from Carbon_automation_test"),
-      Seq(Row(7))
-    )
-  }
-  )
 
   //TC_095
   test(
     "select min (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-    "Carbon_automation_test"
+      "Carbon_automation_test"
   )({
     checkAnswer(
       sql(
         "select min (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-        "Carbon_automation_test"
+          "Carbon_automation_test"
       ),
-      Seq(Row(1))
+      sql(
+        "select min (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
+          "Carbon_automation_hive"
+      )
     )
   }
   )
@@ -831,49 +495,26 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select max(deviceInformationId) a  from Carbon_automation_test")({
     checkAnswer(
       sql("select max(deviceInformationId) a  from Carbon_automation_test"),
-      Seq(Row(1000000))
-    )
-  }
-  )
-
-  //TC_098
-  test("select max(channelsId) a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select max(channelsId) a  from Carbon_automation_test"),
-      Seq(Row("7"))
-    )
-  }
-  )
-
-  //TC_099
-  test("select max(bomCode)  a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select max(bomCode)  a  from Carbon_automation_test"),
-      Seq(Row("100084"))
+      sql("select max(deviceInformationId) a  from Carbon_automation_hive")
     )
   }
   )
 
-  //TC_100
-  test("select max(Latest_MONTH)  a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select max(Latest_MONTH)  a  from Carbon_automation_test"),
-      Seq(Row(7))
-    )
-  }
-  )
 
   //TC_102
   test(
     "select max (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-    "Carbon_automation_test"
+      "Carbon_automation_test"
   )({
     checkAnswer(
       sql(
         "select max (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
-        "Carbon_automation_test"
+          "Carbon_automation_test"
       ),
-      Seq(Row(100))
+      sql(
+        "select max (if(deviceInformationId>100,NULL,deviceInformationId))  a from " +
+          "Carbon_automation_hive"
+      )
     )
   }
   )
@@ -890,7 +531,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select var_samp(deviceInformationId) as a  from Carbon_automation_test")({
     checkAnswer(
       sql("select var_samp(deviceInformationId) as a  from Carbon_automation_test"),
-      Seq(Row(9.405419800040813E9))
+      sql("select var_samp(deviceInformationId) as a  from Carbon_automation_hive")
     )
   }
   )
@@ -899,7 +540,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select stddev_pop(deviceInformationId) as a  from Carbon_automation_test")({
     checkAnswer(
       sql("select stddev_pop(deviceInformationId) as a  from Carbon_automation_test"),
-      Seq(Row(96490.49465950707))
+      sql("select stddev_pop(deviceInformationId) as a  from Carbon_automation_hive")
     )
   }
   )
@@ -908,23 +549,26 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select stddev_samp(deviceInformationId)  as a from Carbon_automation_test")({
     checkAnswer(
       sql("select stddev_samp(deviceInformationId)  as a from Carbon_automation_test"),
-      Seq(Row(96981.54360516652))
+      sql("select stddev_samp(deviceInformationId)  as a from Carbon_automation_hive")
     )
   }
   )
 
   //TC_108
   test("select covar_pop(deviceInformationId,deviceInformationId) as a  from " +
-       "Carbon_automation_test")(
-  {
-    checkAnswer(
-      sql(
-        "select covar_pop(deviceInformationId,deviceInformationId) as a  from " +
-        "Carbon_automation_test"
-      ),
-      Seq(Row(9310415559.636362))
-    )
-  }
+    "Carbon_automation_test")(
+    {
+      checkAnswer(
+        sql(
+          "select covar_pop(deviceInformationId,deviceInformationId) as a  from " +
+            "Carbon_automation_test"
+        ),
+        sql(
+          "select covar_pop(deviceInformationId,deviceInformationId) as a  from " +
+            "Carbon_automation_hive"
+        )
+      )
+    }
   )
 
   //TC_109
@@ -934,9 +578,12 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
     checkAnswer(
       sql(
         "select covar_samp(deviceInformationId,deviceInformationId) as a  from " +
-        "Carbon_automation_test"
+          "Carbon_automation_test"
       ),
-      Seq(Row(9.405419800040813E9))
+      sql(
+        "select covar_samp(deviceInformationId,deviceInformationId) as a  from " +
+          "Carbon_automation_hive"
+      )
     )
   }
   )
@@ -945,7 +592,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select corr(deviceInformationId,deviceInformationId)  as a from Carbon_automation_test")({
     checkAnswer(
       sql("select corr(deviceInformationId,deviceInformationId)  as a from Carbon_automation_test"),
-      Seq(Row(1.0000000000000002))
+      sql("select corr(deviceInformationId,deviceInformationId)  as a from Carbon_automation_hive")
     )
   }
   )
@@ -954,7 +601,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select percentile(deviceInformationId,0.2) as  a  from Carbon_automation_test")({
     checkAnswer(
       sql("select percentile(deviceInformationId,0.2) as  a  from Carbon_automation_test"),
-      Seq(Row(100006.6))
+      sql("select percentile(deviceInformationId,0.2) as  a  from Carbon_automation_hive")
     )
   }
   )
@@ -963,23 +610,16 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select percentile_approx(deviceInformationId,0.2) as a  from Carbon_automation_test")({
     checkAnswer(
       sql("select percentile_approx(deviceInformationId,0.2) as a  from Carbon_automation_test"),
-      Seq(Row(100005.8))
-    )
-  }
-  )
-  //TC_127
-  test("select percentile(deviceInformationId,0.2) as  a  from Carbon_automation_test1")({
-    checkAnswer(
-      sql("select percentile(deviceInformationId,0.2) as  a  from Carbon_automation_test"),
-      Seq(Row(100006.6))
+      sql("select percentile_approx(deviceInformationId,0.2) as a  from Carbon_automation_hive")
     )
   }
   )
+
   //TC_134
   test("select last(imei) a from Carbon_automation_test")({
     checkAnswer(
       sql("select last(imei) a from Carbon_automation_test"),
-      Seq(Row("1AA100084"))
+      sql("select last(imei) a from Carbon_automation_hive")
     )
   }
   )
@@ -987,18 +627,9 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select series,count(imei) a from Carbon_automation_test group by series order by series")({
     checkAnswer(
       sql("select series,count(imei) a from Carbon_automation_test group by series order by " +
-          "series"),
-      Seq(Row("0Series", 15),
-        Row("1Series", 3),
-        Row("2Series", 9),
-        Row("3Series", 8),
-        Row("4Series", 8),
-        Row("5Series", 17),
-        Row("6Series", 9),
-        Row("7Series", 11),
-        Row("8Series", 11),
-        Row("9Series", 8)
-      )
+        "series"),
+      sql("select series,count(imei) a from Carbon_automation_hive group by series order by " +
+        "series")
     )
   }
   )
@@ -1006,80 +637,16 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //TC_138
   test(
     "select series,ActiveProvince,count(imei)  a from Carbon_automation_test group by " +
-    "ActiveProvince,series order by series,ActiveProvince"
+      "ActiveProvince,series order by series,ActiveProvince"
   )({
     checkAnswer(
       sql(
         "select series,ActiveProvince,count(imei)  a from Carbon_automation_test group by " +
-        "ActiveProvince,series order by series,ActiveProvince"
-      ),
-      Seq(Row("0Series", "Guangdong Province", 1),
-        Row("0Series", "Hubei Province", 5),
-        Row("0Series", "Hunan Province", 9),
-        Row("1Series", "Guangdong Province", 2),
-        Row("1Series", "Hunan Province", 1),
-        Row("2Series", "Hubei Province", 3),
-        Row("2Series", "Hunan Province", 6),
-        Row("3Series", "Guangdong Province", 2),
-        Row("3Series", "Hubei Province", 2),
-        Row("3Series", "Hunan Province", 4),
-        Row("4Series", "Guangdong Province", 1),
-        Row("4Series", "Hubei Province", 1),
-        Row("4Series", "Hunan Province", 6),
-        Row("5Series", "Guangdong Province", 5),
-        Row("5Series", "Hubei Province", 3),
-        Row("5Series", "Hunan Province", 9),
-        Row("6Series", "Guangdong Province", 1),
-        Row("6Series", "Hubei Province", 4),
-        Row("6Series", "Hunan Province", 4),
-        Row("7Series", "Guangdong Province", 5),
-        Row("7Series", "Hubei Province", 1),
-        Row("7Series", "Hunan Province", 5),
-        Row("8Series", "Guangdong Province", 2),
-        Row("8Series", "Hubei Province", 6),
-        Row("8Series", "Hunan Province", 3),
-        Row("9Series", "Guangdong Province", 1),
-        Row("9Series", "Hubei Province", 3),
-        Row("9Series", "Hunan Province", 4)
-      )
-    )
-  }
-  )
-
-  //TC_139
-  test(
-    "select count(distinct deviceColor) a,deliveryProvince from Carbon_automation_test group by " +
-    "deliveryProvince"
-  )({
-    checkAnswer(
-      sql(
-        "select count(distinct deviceColor) a,deliveryProvince from Carbon_automation_test group " +
-        "by deliveryProvince"
+          "ActiveProvince,series order by series,ActiveProvince"
       ),
-      Seq(Row(10, "Hunan Province"), Row(10, "Guangdong Province"), Row(10, "Hubei Province"))
-    )
-  }
-  )
-
-  //TC_141
-  test(
-    "select series,sum(gamePointId) a from Carbon_automation_test group by series order by series"
-  )({
-    checkAnswer(
       sql(
-        "select series,sum(gamePointId) a from Carbon_automation_test group by series order by " +
-        "series"
-      ),
-      Seq(Row("0Series", 25880.0),
-        Row("1Series", 4001.0),
-        Row("2Series", 12354.0),
-        Row("3Series", 15235.0),
-        Row("4Series", 12344.0),
-        Row("5Series", 29071.0),
-        Row("6Series", 12922.0),
-        Row("7Series", 18591.197),
-        Row("8Series", 13567.0),
-        Row("9Series", 12920.0)
+        "select series,ActiveProvince,count(imei)  a from Carbon_automation_hive group by " +
+          "ActiveProvince,series order by series,ActiveProvince"
       )
     )
   }
@@ -1088,27 +655,16 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //TC_162
   test(
     "select imei,series from Carbon_automation_test where Carbon_automation_test.series IN " +
-    "('1Series','7Series')"
+      "('1Series','7Series')"
   )({
     checkAnswer(
       sql(
         "select imei,series from Carbon_automation_test where Carbon_automation_test.series IN " +
-        "('1Series','7Series')"
+          "('1Series','7Series')"
       ),
-      Seq(Row("1AA1", "7Series"),
-        Row("1AA10", "7Series"),
-        Row("1AA10000", "7Series"),
-        Row("1AA1000000", "7Series"),
-        Row("1AA100005", "1Series"),
-        Row("1AA100013", "1Series"),
-        Row("1AA100026", "7Series"),
-        Row("1AA10003", "7Series"),
-        Row("1AA100030", "7Series"),
-        Row("1AA100031", "7Series"),
-        Row("1AA100032", "1Series"),
-        Row("1AA100037", "7Series"),
-        Row("1AA100054", "7Series"),
-        Row("1AA100055", "7Series")
+      sql(
+        "select imei,series from Carbon_automation_hive where Carbon_automation_hive.series IN " +
+          "('1Series','7Series')"
       )
     )
   }
@@ -1117,98 +673,16 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //TC_163
   test(
     "select imei,series from Carbon_automation_test where Carbon_automation_test.series  NOT IN " +
-    "('1Series','7Series')"
+      "('1Series','7Series')"
   )({
     checkAnswer(
       sql(
         "select imei,series from Carbon_automation_test where Carbon_automation_test.series  NOT " +
-        "IN ('1Series','7Series')"
+          "IN ('1Series','7Series')"
       ),
-      Seq(Row("1AA100", "5Series"),
-        Row("1AA1000", "5Series"),
-        Row("1AA100000", "9Series"),
-        Row("1AA100001", "0Series"),
-        Row("1AA100002", "0Series"),
-        Row("1AA100003", "5Series"),
-        Row("1AA100004", "4Series"),
-        Row("1AA100006", "6Series"),
-        Row("1AA100007", "9Series"),
-        Row("1AA100008", "8Series"),
-        Row("1AA100009", "0Series"),
-        Row("1AA10001", "2Series"),
-        Row("1AA100010", "3Series"),
-        Row("1AA100011", "0Series"),
-        Row("1AA100012", "4Series"),
-        Row("1AA100014", "5Series"),
-        Row("1AA100015", "4Series"),
-        Row("1AA100016", "3Series"),
-        Row("1AA100017", "9Series"),
-        Row("1AA100018", "8Series"),
-        Row("1AA100019", "5Series"),
-        Row("1AA10002", "0Series"),
-        Row("1AA100020", "5Series"),
-        Row("1AA100021", "0Series"),
-        Row("1AA100022", "5Series"),
-        Row("1AA100023", "5Series"),
-        Row("1AA100024", "6Series"),
-        Row("1AA100025", "0Series"),
-        Row("1AA100027", "0Series"),
-        Row("1AA100028", "5Series"),
-        Row("1AA100029", "2Series"),
-        Row("1AA100033", "8Series"),
-        Row("1AA100034", "2Series"),
-        Row("1AA100035", "5Series"),
-        Row("1AA100036", "5Series"),
-        Row("1AA100038", "6Series"),
-        Row("1AA100039", "8Series"),
-        Row("1AA10004", "5Series"),
-        Row("1AA100040", "8Series"),
-        Row("1AA100041", "5Series"),
-        Row("1AA100042", "3Series"),
-        Row("1AA100043", "9Series"),
-        Row("1AA100044", "8Series"),
-        Row("1AA100045", "2Series"),
-        Row("1AA100046", "3Series"),
-        Row("1AA100047", "9Series"),
-        Row("1AA100048", "3Series"),
-        Row("1AA100049", "0Series"),
-        Row("1AA10005", "8Series"),
-        Row("1AA100050", "2Series"),
-        Row("1AA100051", "2Series"),
-        Row("1AA100052", "6Series"),
-        Row("1AA100053", "2Series"),
-        Row("1AA100056", "6Series"),
-        Row("1AA100057", "9Series"),
-        Row("1AA100058", "5Series"),
-        Row("1AA100059", "4Series"),
-        Row("1AA10006", "3Series"),
-        Row("1AA100060", "8Series"),
-        Row("1AA100061", "6Series"),
-        Row("1AA100062", "9Series"),
-        Row("1AA100063", "2Series"),
-        Row("1AA100064", "6Series"),
-        Row("1AA100065", "0Series"),
-        Row("1AA100066", "6Series"),
-        Row("1AA100067", "4Series"),
-        Row("1AA100068", "8Series"),
-        Row("1AA100069", "8Series"),
-        Row("1AA10007", "8Series"),
-        Row("1AA100070", "0Series"),
-        Row("1AA100071", "0Series"),
-        Row("1AA100072", "4Series"),
-        Row("1AA100073", "4Series"),
-        Row("1AA100074", "6Series"),
-        Row("1AA100075", "3Series"),
-        Row("1AA100076", "0Series"),
-        Row("1AA100077", "3Series"),
-        Row("1AA100078", "2Series"),
-        Row("1AA100079", "4Series"),
-        Row("1AA10008", "5Series"),
-        Row("1AA100080", "9Series"),
-        Row("1AA100081", "5Series"),
-        Row("1AA100082", "5Series"),
-        Row("1AA100083", "0Series"),
-        Row("1AA100084", "0Series")
+      sql(
+        "select imei,series from Carbon_automation_hive where Carbon_automation_hive.series  NOT " +
+          "IN ('1Series','7Series')"
       )
     )
   }
@@ -1218,233 +692,16 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select Upper(series) a  from Carbon_automation_test")({
     checkAnswer(
       sql("select Upper(series) a  from Carbon_automation_test"),
-      Seq(Row("7SERIES"),
-        Row("7SERIES"),
-        Row("5SERIES"),
-        Row("5SERIES"),
-        Row("7SERIES"),
-        Row("9SERIES"),
-        Row("7SERIES"),
-        Row("0SERIES"),
-        Row("0SERIES"),
-        Row("5SERIES"),
-        Row("4SERIES"),
-        Row("1SERIES"),
-        Row("6SERIES"),
-        Row("9SERIES"),
-        Row("8SERIES"),
-        Row("0SERIES"),
-        Row("2SERIES"),
-        Row("3SERIES"),
-        Row("0SERIES"),
-        Row("4SERIES"),
-        Row("1SERIES"),
-        Row("5SERIES"),
-        Row("4SERIES"),
-        Row("3SERIES"),
-        Row("9SERIES"),
-        Row("8SERIES"),
-        Row("5SERIES"),
-        Row("0SERIES"),
-        Row("5SERIES"),
-        Row("0SERIES"),
-        Row("5SERIES"),
-        Row("5SERIES"),
-        Row("6SERIES"),
-        Row("0SERIES"),
-        Row("7SERIES"),
-        Row("0SERIES"),
-        Row("5SERIES"),
-        Row("2SERIES"),
-        Row("7SERIES"),
-        Row("7SERIES"),
-        Row("7SERIES"),
-        Row("1SERIES"),
-        Row("8SERIES"),
-        Row("2SERIES"),
-        Row("5SERIES"),
-        Row("5SERIES"),
-        Row("7SERIES"),
-        Row("6SERIES"),
-        Row("8SERIES"),
-        Row("5SERIES"),
-        Row("8SERIES"),
-        Row("5SERIES"),
-        Row("3SERIES"),
-        Row("9SERIES"),
-        Row("8SERIES"),
-        Row("2SERIES"),
-        Row("3SERIES"),
-        Row("9SERIES"),
-        Row("3SERIES"),
-        Row("0SERIES"),
-        Row("8SERIES"),
-        Row("2SERIES"),
-        Row("2SERIES"),
-        Row("6SERIES"),
-        Row("2SERIES"),
-        Row("7SERIES"),
-        Row("7SERIES"),
-        Row("6SERIES"),
-        Row("9SERIES"),
-        Row("5SERIES"),
-        Row("4SERIES"),
-        Row("3SERIES"),
-        Row("8SERIES"),
-        Row("6SERIES"),
-        Row("9SERIES"),
-        Row("2SERIES"),
-        Row("6SERIES"),
-        Row("0SERIES"),
-        Row("6SERIES"),
-        Row("4SERIES"),
-        Row("8SERIES"),
-        Row("8SERIES"),
-        Row("8SERIES"),
-        Row("0SERIES"),
-        Row("0SERIES"),
-        Row("4SERIES"),
-        Row("4SERIES"),
-        Row("6SERIES"),
-        Row("3SERIES"),
-        Row("0SERIES"),
-        Row("3SERIES"),
-        Row("2SERIES"),
-        Row("4SERIES"),
-        Row("5SERIES"),
-        Row("9SERIES"),
-        Row("5SERIES"),
-        Row("5SERIES"),
-        Row("0SERIES"),
-        Row("0SERIES")
-      )
+      sql("select Upper(series) a  from Carbon_automation_hive")
     )
   }
   )
 
-  //TC_167
-  test("select Upper(Latest_DAY) a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select Upper(Latest_DAY) a  from Carbon_automation_test"),
-      Seq(Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1")
-      )
-    )
-  }
-  )
-
-  //TC_168
-  test("select imei,series from Carbon_automation_test limit 10")({
+  //TC_168
+  test("select imei,series from Carbon_automation_test limit 10")({
     checkAnswer(
       sql("select imei,series from Carbon_automation_test limit 10"),
-      Seq(Row("1AA1", "7Series"),
-        Row("1AA10", "7Series"),
-        Row("1AA100", "5Series"),
-        Row("1AA1000", "5Series"),
-        Row("1AA10000", "7Series"),
-        Row("1AA100000", "9Series"),
-        Row("1AA1000000", "7Series"),
-        Row("1AA100001", "0Series"),
-        Row("1AA100002", "0Series"),
-        Row("1AA100003", "5Series")
-      )
+      sql("select imei,series from Carbon_automation_hive limit 10")
     )
   }
   )
@@ -1453,214 +710,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select Lower(series) a  from Carbon_automation_test")({
     checkAnswer(
       sql("select Lower(series) a  from Carbon_automation_test"),
-      Seq(Row("7series"),
-        Row("7series"),
-        Row("5series"),
-        Row("5series"),
-        Row("7series"),
-        Row("9series"),
-        Row("7series"),
-        Row("0series"),
-        Row("0series"),
-        Row("5series"),
-        Row("4series"),
-        Row("1series"),
-        Row("6series"),
-        Row("9series"),
-        Row("8series"),
-        Row("0series"),
-        Row("2series"),
-        Row("3series"),
-        Row("0series"),
-        Row("4series"),
-        Row("1series"),
-        Row("5series"),
-        Row("4series"),
-        Row("3series"),
-        Row("9series"),
-        Row("8series"),
-        Row("5series"),
-        Row("0series"),
-        Row("5series"),
-        Row("0series"),
-        Row("5series"),
-        Row("5series"),
-        Row("6series"),
-        Row("0series"),
-        Row("7series"),
-        Row("0series"),
-        Row("5series"),
-        Row("2series"),
-        Row("7series"),
-        Row("7series"),
-        Row("7series"),
-        Row("1series"),
-        Row("8series"),
-        Row("2series"),
-        Row("5series"),
-        Row("5series"),
-        Row("7series"),
-        Row("6series"),
-        Row("8series"),
-        Row("5series"),
-        Row("8series"),
-        Row("5series"),
-        Row("3series"),
-        Row("9series"),
-        Row("8series"),
-        Row("2series"),
-        Row("3series"),
-        Row("9series"),
-        Row("3series"),
-        Row("0series"),
-        Row("8series"),
-        Row("2series"),
-        Row("2series"),
-        Row("6series"),
-        Row("2series"),
-        Row("7series"),
-        Row("7series"),
-        Row("6series"),
-        Row("9series"),
-        Row("5series"),
-        Row("4series"),
-        Row("3series"),
-        Row("8series"),
-        Row("6series"),
-        Row("9series"),
-        Row("2series"),
-        Row("6series"),
-        Row("0series"),
-        Row("6series"),
-        Row("4series"),
-        Row("8series"),
-        Row("8series"),
-        Row("8series"),
-        Row("0series"),
-        Row("0series"),
-        Row("4series"),
-        Row("4series"),
-        Row("6series"),
-        Row("3series"),
-        Row("0series"),
-        Row("3series"),
-        Row("2series"),
-        Row("4series"),
-        Row("5series"),
-        Row("9series"),
-        Row("5series"),
-        Row("5series"),
-        Row("0series"),
-        Row("0series")
-      )
-    )
-  }
-  )
-
-  //TC_172
-  test("select Lower(Latest_DAY) a  from Carbon_automation_test")({
-    checkAnswer(
-      sql("select Lower(Latest_DAY) a  from Carbon_automation_test"),
-      Seq(Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1"),
-        Row("1")
-      )
+      sql("select Lower(series) a  from Carbon_automation_hive")
     )
   }
   )
@@ -1669,35 +719,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select distinct  Latest_DAY from Carbon_automation_test")({
     checkAnswer(
       sql("select distinct  Latest_DAY from Carbon_automation_test"),
-      Seq(Row(1))
-    )
-  }
-  )
-
-  //TC_175
-  test("select distinct  channelsId from Carbon_automation_test")({
-    checkAnswer(
-      sql("select distinct  channelsId from Carbon_automation_test"),
-      Seq(Row("1"), Row("2"), Row("3"), Row("4"), Row("5"), Row("6"), Row("7"))
-    )
-  }
-  )
-
-  //TC_176
-  test("select distinct  series from Carbon_automation_test")({
-    checkAnswer(
-      sql("select distinct  series from Carbon_automation_test"),
-      Seq(Row("6Series"),
-        Row("0Series"),
-        Row("4Series"),
-        Row("8Series"),
-        Row("7Series"),
-        Row("1Series"),
-        Row("5Series"),
-        Row("9Series"),
-        Row("3Series"),
-        Row("2Series")
-      )
+      sql("select distinct  Latest_DAY from Carbon_automation_hive")
     )
   }
   )
@@ -1706,124 +728,17 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select distinct count(series) as a  from Carbon_automation_test group by channelsName")({
     checkAnswer(
       sql("select distinct count(series) as a  from Carbon_automation_test group by channelsName"),
-      Seq(Row(10), Row(12), Row(16), Row(18), Row(19))
+      sql("select distinct count(series) as a  from Carbon_automation_hive group by channelsName")
     )
   }
   )
 
-  //TC_178
-  test("select distinct count(gamePointId) a from Carbon_automation_test group by channelsName")({
-    checkAnswer(
-      sql("select distinct count(gamePointId) a from Carbon_automation_test group by channelsName"),
-      Seq(Row(10), Row(12), Row(16), Row(18), Row(19))
-    )
-  }
-  )
 
   //TC_179
   test("select imei,series from Carbon_automation_test limit 101")({
     checkAnswer(
       sql("select imei,series from Carbon_automation_test limit 101"),
-      Seq(Row("1AA1", "7Series"),
-        Row("1AA10", "7Series"),
-        Row("1AA100", "5Series"),
-        Row("1AA1000", "5Series"),
-        Row("1AA10000", "7Series"),
-        Row("1AA100000", "9Series"),
-        Row("1AA1000000", "7Series"),
-        Row("1AA100001", "0Series"),
-        Row("1AA100002", "0Series"),
-        Row("1AA100003", "5Series"),
-        Row("1AA100004", "4Series"),
-        Row("1AA100005", "1Series"),
-        Row("1AA100006", "6Series"),
-        Row("1AA100007", "9Series"),
-        Row("1AA100008", "8Series"),
-        Row("1AA100009", "0Series"),
-        Row("1AA10001", "2Series"),
-        Row("1AA100010", "3Series"),
-        Row("1AA100011", "0Series"),
-        Row("1AA100012", "4Series"),
-        Row("1AA100013", "1Series"),
-        Row("1AA100014", "5Series"),
-        Row("1AA100015", "4Series"),
-        Row("1AA100016", "3Series"),
-        Row("1AA100017", "9Series"),
-        Row("1AA100018", "8Series"),
-        Row("1AA100019", "5Series"),
-        Row("1AA10002", "0Series"),
-        Row("1AA100020", "5Series"),
-        Row("1AA100021", "0Series"),
-        Row("1AA100022", "5Series"),
-        Row("1AA100023", "5Series"),
-        Row("1AA100024", "6Series"),
-        Row("1AA100025", "0Series"),
-        Row("1AA100026", "7Series"),
-        Row("1AA100027", "0Series"),
-        Row("1AA100028", "5Series"),
-        Row("1AA100029", "2Series"),
-        Row("1AA10003", "7Series"),
-        Row("1AA100030", "7Series"),
-        Row("1AA100031", "7Series"),
-        Row("1AA100032", "1Series"),
-        Row("1AA100033", "8Series"),
-        Row("1AA100034", "2Series"),
-        Row("1AA100035", "5Series"),
-        Row("1AA100036", "5Series"),
-        Row("1AA100037", "7Series"),
-        Row("1AA100038", "6Series"),
-        Row("1AA100039", "8Series"),
-        Row("1AA10004", "5Series"),
-        Row("1AA100040", "8Series"),
-        Row("1AA100041", "5Series"),
-        Row("1AA100042", "3Series"),
-        Row("1AA100043", "9Series"),
-        Row("1AA100044", "8Series"),
-        Row("1AA100045", "2Series"),
-        Row("1AA100046", "3Series"),
-        Row("1AA100047", "9Series"),
-        Row("1AA100048", "3Series"),
-        Row("1AA100049", "0Series"),
-        Row("1AA10005", "8Series"),
-        Row("1AA100050", "2Series"),
-        Row("1AA100051", "2Series"),
-        Row("1AA100052", "6Series"),
-        Row("1AA100053", "2Series"),
-        Row("1AA100054", "7Series"),
-        Row("1AA100055", "7Series"),
-        Row("1AA100056", "6Series"),
-        Row("1AA100057", "9Series"),
-        Row("1AA100058", "5Series"),
-        Row("1AA100059", "4Series"),
-        Row("1AA10006", "3Series"),
-        Row("1AA100060", "8Series"),
-        Row("1AA100061", "6Series"),
-        Row("1AA100062", "9Series"),
-        Row("1AA100063", "2Series"),
-        Row("1AA100064", "6Series"),
-        Row("1AA100065", "0Series"),
-        Row("1AA100066", "6Series"),
-        Row("1AA100067", "4Series"),
-        Row("1AA100068", "8Series"),
-        Row("1AA100069", "8Series"),
-        Row("1AA10007", "8Series"),
-        Row("1AA100070", "0Series"),
-        Row("1AA100071", "0Series"),
-        Row("1AA100072", "4Series"),
-        Row("1AA100073", "4Series"),
-        Row("1AA100074", "6Series"),
-        Row("1AA100075", "3Series"),
-        Row("1AA100076", "0Series"),
-        Row("1AA100077", "3Series"),
-        Row("1AA100078", "2Series"),
-        Row("1AA100079", "4Series"),
-        Row("1AA10008", "5Series"),
-        Row("1AA100080", "9Series"),
-        Row("1AA100081", "5Series"),
-        Row("1AA100082", "5Series"),
-        Row("1AA100083", "0Series"),
-        Row("1AA100084", "0Series")
-      )
+      sql("select imei,series from Carbon_automation_hive limit 101")
     )
   }
   )
@@ -1831,214 +746,70 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //TC_180
   test(
     "select series,sum(gamePointId) a from Carbon_automation_test group by series order by series" +
-    " desc"
+      " desc"
   )({
     checkAnswer(
       sql(
         "select series,sum(gamePointId) a from Carbon_automation_test group by series order by " +
-        "series desc"
+          "series desc"
       ),
-      Seq(Row("9Series", 12920.0),
-        Row("8Series", 13567.0),
-        Row("7Series", 18591.197),
-        Row("6Series", 12922.0),
-        Row("5Series", 29071.0),
-        Row("4Series", 12344.0),
-        Row("3Series", 15235.0),
-        Row("2Series", 12354.0),
-        Row("1Series", 4001.0),
-        Row("0Series", 25880.0)
-      )
-    )
-  }
-  )
-
-  //TC_181
-  test(
-    "select series,sum(gamePointId) a from Carbon_automation_test group by series order by a desc"
-  )({
-    checkAnswer(
       sql(
-        "select series,sum(gamePointId) a from Carbon_automation_test group by series order by a " +
-        "desc"
-      ),
-      Seq(Row("5Series", 29071.0),
-        Row("0Series", 25880.0),
-        Row("7Series", 18591.197),
-        Row("3Series", 15235.0),
-        Row("8Series", 13567.0),
-        Row("6Series", 12922.0),
-        Row("9Series", 12920.0),
-        Row("2Series", 12354.0),
-        Row("4Series", 12344.0),
-        Row("1Series", 4001.0)
+        "select series,sum(gamePointId) a from Carbon_automation_hive group by series order by " +
+          "series desc"
       )
     )
   }
   )
 
+
   //TC_182
   test(
     "select series,sum(gamePointId) a from Carbon_automation_test group by series order by series" +
-    " desc ,a desc"
+      " desc ,a desc"
   )({
     checkAnswer(
       sql(
         "select series,sum(gamePointId) a from Carbon_automation_test group by series order by " +
-        "series desc ,a desc"
+          "series desc ,a desc"
       ),
-      Seq(Row("9Series", 12920.0),
-        Row("8Series", 13567.0),
-        Row("7Series", 18591.197),
-        Row("6Series", 12922.0),
-        Row("5Series", 29071.0),
-        Row("4Series", 12344.0),
-        Row("3Series", 15235.0),
-        Row("2Series", 12354.0),
-        Row("1Series", 4001.0),
-        Row("0Series", 25880.0)
-      )
-    )
+      sql(
+        "select series,sum(gamePointId) a from Carbon_automation_hive group by series order by " +
+          "series desc ,a desc"
+      ))
   }
   )
 
   //TC_183
   test(
     "select series,sum(gamePointId) a from Carbon_automation_test group by series order by series" +
-    " asc"
+      " asc"
   )({
     checkAnswer(
       sql(
         "select series,sum(gamePointId) a from Carbon_automation_test group by series order by " +
-        "series asc"
+          "series asc"
       ),
-      Seq(Row("0Series", 25880.0),
-        Row("1Series", 4001.0),
-        Row("2Series", 12354.0),
-        Row("3Series", 15235.0),
-        Row("4Series", 12344.0),
-        Row("5Series", 29071.0),
-        Row("6Series", 12922.0),
-        Row("7Series", 18591.197),
-        Row("8Series", 13567.0),
-        Row("9Series", 12920.0)
-      )
-    )
-  }
-  )
-
-  //TC_184
-  test("select series,sum(gamePointId) a from Carbon_automation_test group by series order by a " +
-       "asc")(
-  {
-    checkAnswer(
       sql(
-        "select series,sum(gamePointId) a from Carbon_automation_test group by series order by a " +
-        "asc"
-      ),
-      Seq(Row("1Series", 4001.0),
-        Row("4Series", 12344.0),
-        Row("2Series", 12354.0),
-        Row("9Series", 12920.0),
-        Row("6Series", 12922.0),
-        Row("8Series", 13567.0),
-        Row("3Series", 15235.0),
-        Row("7Series", 18591.197),
-        Row("0Series", 25880.0),
-        Row("5Series", 29071.0)
+        "select series,sum(gamePointId) a from Carbon_automation_hive group by series order by " +
+          "series asc"
       )
     )
   }
   )
 
-  //TC_185
-  test(
-    "select series,sum(gamePointId) a from Carbon_automation_test group by series order by series" +
-    " asc ,a asc"
-  )({
-    checkAnswer(
-      sql(
-        "select series,sum(gamePointId) a from Carbon_automation_test group by series order by " +
-        "series asc ,a asc"
-      ),
-      Seq(Row("0Series", 25880.0),
-        Row("1Series", 4001.0),
-        Row("2Series", 12354.0),
-        Row("3Series", 15235.0),
-        Row("4Series", 12344.0),
-        Row("5Series", 29071.0),
-        Row("6Series", 12922.0),
-        Row("7Series", 18591.197),
-        Row("8Series", 13567.0),
-        Row("9Series", 12920.0)
-      )
-    )
-  }
-  )
 
-  //TC_186
   test(
     "select series,sum(gamePointId) a from Carbon_automation_test group by series order by series" +
-    " desc ,a asc"
+      " asc ,a asc"
   )({
     checkAnswer(
       sql(
         "select series,sum(gamePointId) a from Carbon_automation_test group by series order by " +
-        "series desc ,a asc"
+          "series asc ,a asc"
       ),
-      Seq(Row("9Series", 12920.0),
-        Row("8Series", 13567.0),
-        Row("7Series", 18591.197),
-        Row("6Series", 12922.0),
-        Row("5Series", 29071.0),
-        Row("4Series", 12344.0),
-        Row("3Series", 15235.0),
-        Row("2Series", 12354.0),
-        Row("1Series", 4001.0),
-        Row("0Series", 25880.0)
-      )
-    )
-  }
-  )
-
-  //TC_187
-  test(
-    "select series,ActiveProvince,sum(gamePointId) a from Carbon_automation_test group by series," +
-    "ActiveProvince order by series desc,ActiveProvince asc"
-  )({
-    checkAnswer(
       sql(
-        "select series,ActiveProvince,sum(gamePointId) a from Carbon_automation_test group by " +
-        "series,ActiveProvince order by series desc,ActiveProvince asc"
-      ),
-      Seq(Row("9Series", "Guangdong Province", 2205.0),
-        Row("9Series", "Hubei Province", 2530.0),
-        Row("9Series", "Hunan Province", 8185.0),
-        Row("8Series", "Guangdong Province", 2235.0),
-        Row("8Series", "Hubei Province", 7962.0),
-        Row("8Series", "Hunan Province", 3370.0),
-        Row("7Series", "Guangdong Province", 8935.562),
-        Row("7Series", "Hubei Province", 1714.635),
-        Row("7Series", "Hunan Province", 7941.0),
-        Row("6Series", "Guangdong Province", 907.0),
-        Row("6Series", "Hubei Province", 6504.0),
-        Row("6Series", "Hunan Province", 5511.0),
-        Row("5Series", "Guangdong Province", 8963.0),
-        Row("5Series", "Hubei Province", 6100.0),
-        Row("5Series", "Hunan Province", 14008.0),
-        Row("4Series", "Guangdong Province", 2488.0),
-        Row("4Series", "Hubei Province", 2970.0),
-        Row("4Series", "Hunan Province", 6886.0),
-        Row("3Series", "Guangdong Province", 2586.0),
-        Row("3Series", "Hubei Province", 3555.0),
-        Row("3Series", "Hunan Province", 9094.0),
-        Row("2Series", "Hubei Province", 4016.0),
-        Row("2Series", "Hunan Province", 8338.0),
-        Row("1Series", "Guangdong Province", 1408.0),
-        Row("1Series", "Hunan Province", 2593.0),
-        Row("0Series", "Guangdong Province", 2192.0),
-        Row("0Series", "Hubei Province", 7500.0),
-        Row("0Series", "Hunan Province", 16188.0)
+        "select series,sum(gamePointId) a from Carbon_automation_hive group by series order by " +
+          "series asc ,a asc"
       )
     )
   }
@@ -2048,19 +819,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select Latest_DAY as a from Carbon_automation_test where Latest_DAY<=>Latest_areaId")({
     checkAnswer(
       sql("select Latest_DAY as a from Carbon_automation_test where Latest_DAY<=>Latest_areaId"),
-      Seq(Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1)
-      )
+      sql("select Latest_DAY as a from Carbon_automation_hive where Latest_DAY<=>Latest_areaId")
     )
   }
   )
@@ -2069,94 +828,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select Latest_DAY  from Carbon_automation_test where Latest_DAY<>Latest_areaId")({
     checkAnswer(
       sql("select Latest_DAY  from Carbon_automation_test where Latest_DAY<>Latest_areaId"),
-      Seq(Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1)
-      )
+      sql("select Latest_DAY  from Carbon_automation_hive where Latest_DAY<>Latest_areaId")
     )
   }
   )
@@ -2165,94 +837,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select Latest_DAY from Carbon_automation_test where Latest_DAY != Latest_areaId")({
     checkAnswer(
       sql("select Latest_DAY from Carbon_automation_test where Latest_DAY != Latest_areaId"),
-      Seq(Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1),
-        Row(1)
-      )
+      sql("select Latest_DAY from Carbon_automation_hive where Latest_DAY != Latest_areaId")
     )
   }
   )
@@ -2261,94 +846,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY<Latest_areaId")({
     checkAnswer(
       sql("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY<Latest_areaId"),
-      Seq(Row("1AA1", 1),
-        Row("1AA10", 1),
-        Row("1AA100", 1),
-        Row("1AA1000", 1),
-        Row("1AA10000", 1),
-        Row("1AA100000", 1),
-        Row("1AA100001", 1),
-        Row("1AA100002", 1),
-        Row("1AA100003", 1),
-        Row("1AA100004", 1),
-        Row("1AA100006", 1),
-        Row("1AA100007", 1),
-        Row("1AA100008", 1),
-        Row("1AA100009", 1),
-        Row("1AA10001", 1),
-        Row("1AA100010", 1),
-        Row("1AA100011", 1),
-        Row("1AA100012", 1),
-        Row("1AA100013", 1),
-        Row("1AA100014", 1),
-        Row("1AA100015", 1),
-        Row("1AA100016", 1),
-        Row("1AA100017", 1),
-        Row("1AA100018", 1),
-        Row("1AA100019", 1),
-        Row("1AA10002", 1),
-        Row("1AA100020", 1),
-        Row("1AA100021", 1),
-        Row("1AA100022", 1),
-        Row("1AA100023", 1),
-        Row("1AA100024", 1),
-        Row("1AA100029", 1),
-        Row("1AA10003", 1),
-        Row("1AA100030", 1),
-        Row("1AA100031", 1),
-        Row("1AA100032", 1),
-        Row("1AA100033", 1),
-        Row("1AA100035", 1),
-        Row("1AA100036", 1),
-        Row("1AA100037", 1),
-        Row("1AA100038", 1),
-        Row("1AA10004", 1),
-        Row("1AA100040", 1),
-        Row("1AA100041", 1),
-        Row("1AA100042", 1),
-        Row("1AA100043", 1),
-        Row("1AA100044", 1),
-        Row("1AA100045", 1),
-        Row("1AA100046", 1),
-        Row("1AA100047", 1),
-        Row("1AA100048", 1),
-        Row("1AA100049", 1),
-        Row("1AA10005", 1),
-        Row("1AA100051", 1),
-        Row("1AA100053", 1),
-        Row("1AA100054", 1),
-        Row("1AA100055", 1),
-        Row("1AA100056", 1),
-        Row("1AA100057", 1),
-        Row("1AA100058", 1),
-        Row("1AA100059", 1),
-        Row("1AA10006", 1),
-        Row("1AA100060", 1),
-        Row("1AA100062", 1),
-        Row("1AA100063", 1),
-        Row("1AA100064", 1),
-        Row("1AA100065", 1),
-        Row("1AA100066", 1),
-        Row("1AA100067", 1),
-        Row("1AA100068", 1),
-        Row("1AA100069", 1),
-        Row("1AA10007", 1),
-        Row("1AA100070", 1),
-        Row("1AA100071", 1),
-        Row("1AA100072", 1),
-        Row("1AA100073", 1),
-        Row("1AA100075", 1),
-        Row("1AA100076", 1),
-        Row("1AA100077", 1),
-        Row("1AA100078", 1),
-        Row("1AA100079", 1),
-        Row("1AA10008", 1),
-        Row("1AA100080", 1),
-        Row("1AA100081", 1),
-        Row("1AA100082", 1),
-        Row("1AA100083", 1),
-        Row("1AA100084", 1)
-      )
+      sql("select imei, Latest_DAY from Carbon_automation_hive where Latest_DAY<Latest_areaId")
     )
   }
   )
@@ -2357,106 +855,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY<=Latest_areaId")({
     checkAnswer(
       sql("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY<=Latest_areaId"),
-      Seq(Row("1AA1", 1),
-        Row("1AA10", 1),
-        Row("1AA100", 1),
-        Row("1AA1000", 1),
-        Row("1AA10000", 1),
-        Row("1AA100000", 1),
-        Row("1AA1000000", 1),
-        Row("1AA100001", 1),
-        Row("1AA100002", 1),
-        Row("1AA100003", 1),
-        Row("1AA100004", 1),
-        Row("1AA100005", 1),
-        Row("1AA100006", 1),
-        Row("1AA100007", 1),
-        Row("1AA100008", 1),
-        Row("1AA100009", 1),
-        Row("1AA10001", 1),
-        Row("1AA100010", 1),
-        Row("1AA100011", 1),
-        Row("1AA100012", 1),
-        Row("1AA100013", 1),
-        Row("1AA100014", 1),
-        Row("1AA100015", 1),
-        Row("1AA100016", 1),
-        Row("1AA100017", 1),
-        Row("1AA100018", 1),
-        Row("1AA100019", 1),
-        Row("1AA10002", 1),
-        Row("1AA100020", 1),
-        Row("1AA100021", 1),
-        Row("1AA100022", 1),
-        Row("1AA100023", 1),
-        Row("1AA100024", 1),
-        Row("1AA100025", 1),
-        Row("1AA100026", 1),
-        Row("1AA100027", 1),
-        Row("1AA100028", 1),
-        Row("1AA100029", 1),
-        Row("1AA10003", 1),
-        Row("1AA100030", 1),
-        Row("1AA100031", 1),
-        Row("1AA100032", 1),
-        Row("1AA100033", 1),
-        Row("1AA100034", 1),
-        Row("1AA100035", 1),
-        Row("1AA100036", 1),
-        Row("1AA100037", 1),
-        Row("1AA100038", 1),
-        Row("1AA100039", 1),
-        Row("1AA10004", 1),
-        Row("1AA100040", 1),
-        Row("1AA100041", 1),
-        Row("1AA100042", 1),
-        Row("1AA100043", 1),
-        Row("1AA100044", 1),
-        Row("1AA100045", 1),
-        Row("1AA100046", 1),
-        Row("1AA100047", 1),
-        Row("1AA100048", 1),
-        Row("1AA100049", 1),
-        Row("1AA10005", 1),
-        Row("1AA100050", 1),
-        Row("1AA100051", 1),
-        Row("1AA100052", 1),
-        Row("1AA100053", 1),
-        Row("1AA100054", 1),
-        Row("1AA100055", 1),
-        Row("1AA100056", 1),
-        Row("1AA100057", 1),
-        Row("1AA100058", 1),
-        Row("1AA100059", 1),
-        Row("1AA10006", 1),
-        Row("1AA100060", 1),
-        Row("1AA100061", 1),
-        Row("1AA100062", 1),
-        Row("1AA100063", 1),
-        Row("1AA100064", 1),
-        Row("1AA100065", 1),
-        Row("1AA100066", 1),
-        Row("1AA100067", 1),
-        Row("1AA100068", 1),
-        Row("1AA100069", 1),
-        Row("1AA10007", 1),
-        Row("1AA100070", 1),
-        Row("1AA100071", 1),
-        Row("1AA100072", 1),
-        Row("1AA100073", 1),
-        Row("1AA100074", 1),
-        Row("1AA100075", 1),
-        Row("1AA100076", 1),
-        Row("1AA100077", 1),
-        Row("1AA100078", 1),
-        Row("1AA100079", 1),
-        Row("1AA10008", 1),
-        Row("1AA100080", 1),
-        Row("1AA100081", 1),
-        Row("1AA100082", 1),
-        Row("1AA100083", 1),
-        Row("1AA100084", 1)
-      )
+      sql("select imei, Latest_DAY from Carbon_automation_hive where Latest_DAY<=Latest_areaId")
     )
   }
   )
@@ -2465,19 +864,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY>=Latest_areaId")({
     checkAnswer(
       sql("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY>=Latest_areaId"),
-      Seq(Row("1AA1000000", 1),
-        Row("1AA100005", 1),
-        Row("1AA100025", 1),
-        Row("1AA100026", 1),
-        Row("1AA100027", 1),
-        Row("1AA100028", 1),
-        Row("1AA100034", 1),
-        Row("1AA100039", 1),
-        Row("1AA100050", 1),
-        Row("1AA100052", 1),
-        Row("1AA100061", 1),
-        Row("1AA100074", 1)
-      )
+      sql("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY>=Latest_areaId")
     )
   }
   )
@@ -2485,100 +872,16 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   //TC_216
   test(
     "select imei, Latest_DAY from Carbon_automation_test where Latest_DAY NOT BETWEEN " +
-    "Latest_areaId AND  Latest_HOUR"
+      "Latest_areaId AND  Latest_HOUR"
   )({
     checkAnswer(
       sql(
         "select imei, Latest_DAY from Carbon_automation_test where Latest_DAY NOT BETWEEN " +
-        "Latest_areaId AND  Latest_HOUR"
+          "Latest_areaId AND  Latest_HOUR"
       ),
-      Seq(Row("1AA1", 1),
-        Row("1AA10", 1),
-        Row("1AA100", 1),
-        Row("1AA1000", 1),
-        Row("1AA10000", 1),
-        Row("1AA100000", 1),
-        Row("1AA100001", 1),
-        Row("1AA100002", 1),
-        Row("1AA100003", 1),
-        Row("1AA100004", 1),
-        Row("1AA100006", 1),
-        Row("1AA100007", 1),
-        Row("1AA100008", 1),
-        Row("1AA100009", 1),
-        Row("1AA10001", 1),
-        Row("1AA100010", 1),
-        Row("1AA100011", 1),
-        Row("1AA100012", 1),
-        Row("1AA100013", 1),
-        Row("1AA100014", 1),
-        Row("1AA100015", 1),
-        Row("1AA100016", 1),
-        Row("1AA100017", 1),
-        Row("1AA100018", 1),
-        Row("1AA100019", 1),
-        Row("1AA10002", 1),
-        Row("1AA100020", 1),
-        Row("1AA100021", 1),
-        Row("1AA100022", 1),
-        Row("1AA100023", 1),
-        Row("1AA100024", 1),
-        Row("1AA100029", 1),
-        Row("1AA10003", 1),
-        Row("1AA100030", 1),
-        Row("1AA100031", 1),
-        Row("1AA100032", 1),
-        Row("1AA100033", 1),
-        Row("1AA100035", 1),
-        Row("1AA100036", 1),
-        Row("1AA100037", 1),
-        Row("1AA100038", 1),
-        Row("1AA10004", 1),
-        Row("1AA100040", 1),
-        Row("1AA100041", 1),
-        Row("1AA100042", 1),
-        Row("1AA100043", 1),
-        Row("1AA100044", 1),
-        Row("1AA100045", 1),
-        Row("1AA100046", 1),
-        Row("1AA100047", 1),
-        Row("1AA100048", 1),
-        Row("1AA100049", 1),
-        Row("1AA10005", 1),
-        Row("1AA100051", 1),
-        Row("1AA100053", 1),
-        Row("1AA100054", 1),
-        Row("1AA100055", 1),
-        Row("1AA100056", 1),
-        Row("1AA100057", 1),
-        Row("1AA100058", 1),
-        Row("1AA100059", 1),
-        Row("1AA10006", 1),
-        Row("1AA100060", 1),
-        Row("1AA100062", 1),
-        Row("1AA100063", 1),
-        Row("1AA100064", 1),
-        Row("1AA100065", 1),
-        Row("1AA100066", 1),
-        Row("1AA100067", 1),
-        Row("1AA100068", 1),
-        Row("1AA100069", 1),
-        Row("1AA10007", 1),
-        Row("1AA100070", 1),
-        Row("1AA100071", 1),
-        Row("1AA100072", 1),
-        Row("1AA100073", 1),
-        Row("1AA100075", 1),
-        Row("1AA100076", 1),
-        Row("1AA100077", 1),
-        Row("1AA100078", 1),
-        Row("1AA100079", 1),
-        Row("1AA10008", 1),
-        Row("1AA100080", 1),
-        Row("1AA100081", 1),
-        Row("1AA100082", 1),
-        Row("1AA100083", 1),
-        Row("1AA100084", 1)
+      sql(
+        "select imei, Latest_DAY from Carbon_automation_hive where Latest_DAY NOT BETWEEN " +
+          "Latest_areaId AND  Latest_HOUR"
       )
     )
   }
@@ -2588,214 +891,7 @@ class AllDataTypesTestCase1 extends QueryTest with BeforeAndAfterAll {
   test("select imei, Latest_DAY from Carbon_automation_test where Latest_DAY IS NOT NULL")({
     checkAnswer(
       sql("select imei,

<TRUNCATED>


Mime
View raw message