Github user Sssan520 commented on a diff in the pull request:
https://github.com/apache/carbondata/pull/2436#discussion_r201542881
--- Diff:
integration/spark-common-test/src/test/scala/org/apache/carbondata/spark/testsuite/longstring/VarcharDataTypesBasicTestCase.scala
---
@@ -133,6 +133,64 @@ class VarcharDataTypesBasicTestCase extends QueryTest
with BeforeAndAfterEach wi
assert(exceptionCaught.getMessage.contains("its data type is not
string"))
}
+ test("long string columns cannot contain duplicate columns") {
+ val exceptionCaught = intercept[Exception] {
+ sql(
+ s"""
+ | CREATE TABLE if not exists $longStringTable(
+ | id INT, name STRING, description STRING, address STRING, note
STRING
+ | ) STORED BY 'carbondata'
+ | TBLPROPERTIES('LONG_STRING_COLUMNS'='address, note, Note')
+ |""".
+ stripMargin)
+ }
+ assert(exceptionCaught.getMessage.contains("long_string_columns"))
+ assert(exceptionCaught.getMessage.contains("Duplicate columns are not
allowed"))
+ }
+
+ test("long_string_columns: column does not exist in table ") {
+ val exceptionCaught = intercept[Exception] {
--- End diff --
ok
---