diff --git a/common/utils/src/main/resources/error/error-classes.json b/common/utils/src/main/resources/error/error-classes.json index 717d5e6631ec..f471f9920da5 100644 --- a/common/utils/src/main/resources/error/error-classes.json +++ b/common/utils/src/main/resources/error/error-classes.json @@ -4497,7 +4497,8 @@ "subClass" : { "ACCESSING_OUTER_QUERY_COLUMN_IS_NOT_ALLOWED" : { "message" : [ - "Accessing outer query column is not allowed in this location." + "Accessing outer query column is not allowed in this location:", + "" ] }, "AGGREGATE_FUNCTION_MIXED_OUTER_LOCAL_REFERENCES" : { @@ -4507,7 +4508,8 @@ }, "CORRELATED_COLUMN_IS_NOT_ALLOWED_IN_PREDICATE" : { "message" : [ - "Correlated column is not allowed in predicate: ." + "Correlated column is not allowed in predicate:", + "" ] }, "CORRELATED_COLUMN_NOT_FOUND" : { @@ -4542,7 +4544,8 @@ }, "NON_DETERMINISTIC_LATERAL_SUBQUERIES" : { "message" : [ - "Non-deterministic lateral subqueries are not supported when joining with outer relations that produce more than one row." + "Non-deterministic lateral subqueries are not supported when joining with outer relations that produce more than one row:", + "" ] }, "UNSUPPORTED_CORRELATED_REFERENCE_DATA_TYPE" : { @@ -4552,17 +4555,20 @@ }, "UNSUPPORTED_CORRELATED_SCALAR_SUBQUERY" : { "message" : [ - "Correlated scalar subqueries can only be used in filters, aggregations, projections, and UPDATE/MERGE/DELETE commands." + "Correlated scalar subqueries can only be used in filters, aggregations, projections, and UPDATE/MERGE/DELETE commands:", + "" ] }, "UNSUPPORTED_IN_EXISTS_SUBQUERY" : { "message" : [ - "IN/EXISTS predicate subqueries can only be used in filters, joins, aggregations, window functions, projections, and UPDATE/MERGE/DELETE commands." + "IN/EXISTS predicate subqueries can only be used in filters, joins, aggregations, window functions, projections, and UPDATE/MERGE/DELETE commands:", + "" ] }, "UNSUPPORTED_TABLE_ARGUMENT" : { "message" : [ - "Table arguments are used in a function where they are not supported." + "Table arguments are used in a function where they are not supported:", + "" ] } }, diff --git a/core/src/test/scala/org/apache/spark/SparkThrowableSuite.scala b/core/src/test/scala/org/apache/spark/SparkThrowableSuite.scala index f41ad8fffd3e..367aaeb386da 100644 --- a/core/src/test/scala/org/apache/spark/SparkThrowableSuite.scala +++ b/core/src/test/scala/org/apache/spark/SparkThrowableSuite.scala @@ -150,6 +150,8 @@ class SparkThrowableSuite extends SparkFunSuite { } messageSeq.foreach { message => message.foreach { msg => + // Error messages in the JSON file should not contain newline characters: + // newlines are delineated as different elements in the array. assert(!msg.contains("\n")) assert(msg.trim == msg) } diff --git a/docs/sql-error-conditions-unsupported-subquery-expression-category-error-class.md b/docs/sql-error-conditions-unsupported-subquery-expression-category-error-class.md index 34c070dc97e0..59a34d6a0169 100644 --- a/docs/sql-error-conditions-unsupported-subquery-expression-category-error-class.md +++ b/docs/sql-error-conditions-unsupported-subquery-expression-category-error-class.md @@ -32,7 +32,8 @@ This error class has the following derived error classes: ## ACCESSING_OUTER_QUERY_COLUMN_IS_NOT_ALLOWED -Accessing outer query column is not allowed in this location``. +Accessing outer query column is not allowed in this location: +`` ## AGGREGATE_FUNCTION_MIXED_OUTER_LOCAL_REFERENCES @@ -40,7 +41,8 @@ Found an aggregate function in a correlated predicate that has both outer and lo ## CORRELATED_COLUMN_IS_NOT_ALLOWED_IN_PREDICATE -Correlated column is not allowed in predicate: ``. +Correlated column is not allowed in predicate: +`` ## CORRELATED_COLUMN_NOT_FOUND @@ -68,7 +70,8 @@ A GROUP BY clause in a scalar correlated subquery cannot contain non-correlated ## NON_DETERMINISTIC_LATERAL_SUBQUERIES -Non-deterministic lateral subqueries are not supported when joining with outer relations that produce more than one row``. +Non-deterministic lateral subqueries are not supported when joining with outer relations that produce more than one row: +`` ## UNSUPPORTED_CORRELATED_REFERENCE_DATA_TYPE @@ -76,14 +79,17 @@ Correlated column reference '``' cannot be `` type. ## UNSUPPORTED_CORRELATED_SCALAR_SUBQUERY -Correlated scalar subqueries can only be used in filters, aggregations, projections, and UPDATE/MERGE/DELETE commands``. +Correlated scalar subqueries can only be used in filters, aggregations, projections, and UPDATE/MERGE/DELETE commands: +`` ## UNSUPPORTED_IN_EXISTS_SUBQUERY -IN/EXISTS predicate subqueries can only be used in filters, joins, aggregations, window functions, projections, and UPDATE/MERGE/DELETE commands``. +IN/EXISTS predicate subqueries can only be used in filters, joins, aggregations, window functions, projections, and UPDATE/MERGE/DELETE commands: +`` ## UNSUPPORTED_TABLE_ARGUMENT -Table arguments are used in a function where they are not supported``. +Table arguments are used in a function where they are not supported: +``