|
18 | 18 |
|
19 | 19 | ERROR_CLASSES_JSON = """ |
20 | 20 | { |
| 21 | + "AMBIGUOUS_REFERENCE" : { |
| 22 | + "message" : [ |
| 23 | + "Reference <name> is ambiguous, could be: <referenceNames>." |
| 24 | + ], |
| 25 | + "sqlState" : "42704" |
| 26 | + }, |
21 | 27 | "APPLICATION_NAME_NOT_SET" : { |
22 | 28 | "message" : [ |
23 | 29 | "An application name must be set in your configuration." |
|
106 | 112 | "CANNOT_INFER_EMPTY_SCHEMA": { |
107 | 113 | "message": [ |
108 | 114 | "Can not infer schema from empty dataset." |
109 | | - ] |
| 115 | + ], |
| 116 | + "sqlState": "42K09" |
110 | 117 | }, |
111 | 118 | "CANNOT_INFER_SCHEMA_FOR_TYPE": { |
112 | 119 | "message": [ |
113 | 120 | "Can not infer schema for type: `<data_type>`." |
114 | | - ] |
| 121 | + ], |
| 122 | + "sqlState": "42K09" |
115 | 123 | }, |
116 | 124 | "CANNOT_INFER_TYPE_FOR_FIELD": { |
117 | 125 | "message": [ |
118 | 126 | "Unable to infer the type of the field `<field_name>`." |
119 | | - ] |
| 127 | + ], |
| 128 | + "sqlState": "42K09" |
120 | 129 | }, |
121 | 130 | "CANNOT_MERGE_TYPE": { |
122 | 131 | "message": [ |
123 | 132 | "Can not merge type `<data_type1>` and `<data_type2>`." |
124 | | - ] |
| 133 | + ], |
| 134 | + "sqlState": "42K09" |
125 | 135 | }, |
126 | 136 | "CANNOT_OPEN_SOCKET": { |
127 | 137 | "message": [ |
|
148 | 158 | "returnType can not be specified when `<arg_name>` is a user-defined function, but got <return_type>." |
149 | 159 | ] |
150 | 160 | }, |
| 161 | + "COLUMN_ALREADY_EXISTS" : { |
| 162 | + "message" : [ |
| 163 | + "The column <columnName> already exists. Choose another name or rename the existing column." |
| 164 | + ], |
| 165 | + "sqlState" : "42711" |
| 166 | + }, |
151 | 167 | "COLUMN_IN_LIST": { |
152 | 168 | "message": [ |
153 | 169 | "`<func_name>` does not allow a Column in a list." |
|
230 | 246 | "Duplicated field names in Arrow Struct are not allowed, got <field_names>" |
231 | 247 | ] |
232 | 248 | }, |
| 249 | + "FIELD_NOT_FOUND" : { |
| 250 | + "message" : [ |
| 251 | + "No such struct field <fieldName> in <fields>." |
| 252 | + ], |
| 253 | + "sqlState" : "42704" |
| 254 | + }, |
233 | 255 | "HIGHER_ORDER_FUNCTION_SHOULD_RETURN_COLUMN" : { |
234 | 256 | "message" : [ |
235 | 257 | "Function `<func_name>` should return Column, got <return_type>." |
236 | 258 | ] |
237 | 259 | }, |
| 260 | + "INCOMPATIBLE_COLUMN_TYPE" : { |
| 261 | + "message" : [ |
| 262 | + "<operator> can only be performed on tables with compatible column types. The <columnOrdinalNumber> column of the <tableOrdinalNumber> table is <dataType1> type which is not compatible with <dataType2> at the same column of the first table.<hint>." |
| 263 | + ], |
| 264 | + "sqlState" : "42825" |
| 265 | + }, |
238 | 266 | "INCORRECT_CONF_FOR_PROFILE" : { |
239 | 267 | "message" : [ |
240 | 268 | "`spark.python.profile` or `spark.python.profile.memory` configuration", |
|
286 | 314 | "Pandas UDF should return StructType for <eval_type>, got <return_type>." |
287 | 315 | ] |
288 | 316 | }, |
| 317 | + "INVALID_SAVE_MODE" : { |
| 318 | + "message" : [ |
| 319 | + "The specified save mode <mode> is invalid. Valid save modes include \\"append\\", \\"overwrite\\", \\"ignore\\", \\"error\\", \\"errorifexists\\", and \\"default\\"." |
| 320 | + ], |
| 321 | + "sqlState" : "42000" |
| 322 | + }, |
289 | 323 | "INVALID_TIMEOUT_TIMESTAMP" : { |
290 | 324 | "message" : [ |
291 | 325 | "Timeout timestamp (<timestamp>) cannot be earlier than the current watermark (<watermark>)." |
|
371 | 405 | "A master URL must be set in your configuration." |
372 | 406 | ] |
373 | 407 | }, |
| 408 | + "MISSING_GROUP_BY" : { |
| 409 | + "message" : [ |
| 410 | + "The query does not include a GROUP BY clause. Add GROUP BY or turn it into the window functions using OVER clauses." |
| 411 | + ], |
| 412 | + "sqlState" : "42803" |
| 413 | + }, |
374 | 414 | "MISSING_LIBRARY_FOR_PROFILER" : { |
375 | 415 | "message" : [ |
376 | 416 | "Install the 'memory_profiler' library in the cluster to enable memory profiling." |
|
626 | 666 | "No active Spark session found. Please create a new Spark session before running the code." |
627 | 667 | ] |
628 | 668 | }, |
| 669 | + "NUM_COLUMNS_MISMATCH" : { |
| 670 | + "message" : [ |
| 671 | + "<operator> can only be performed on inputs with the same number of columns, but the first input has <firstNumColumns> columns and the <invalidOrdinalNum> input has <invalidNumColumns> columns." |
| 672 | + ], |
| 673 | + "sqlState" : "42826" |
| 674 | + }, |
629 | 675 | "ONLY_ALLOWED_FOR_SINGLE_COLUMN" : { |
630 | 676 | "message" : [ |
631 | 677 | "Argument `<arg_name>` can only be provided for a single column." |
|
636 | 682 | "Only a single trigger is allowed." |
637 | 683 | ] |
638 | 684 | }, |
| 685 | + "PARSE_SYNTAX_ERROR" : { |
| 686 | + "message" : [ |
| 687 | + "Syntax error at or near <error><hint>." |
| 688 | + ], |
| 689 | + "sqlState" : "42601" |
| 690 | + }, |
| 691 | + "PATH_ALREADY_EXISTS" : { |
| 692 | + "message" : [ |
| 693 | + "Path <outputPath> already exists. Set mode as \\"overwrite\\" to overwrite the existing path." |
| 694 | + ], |
| 695 | + "sqlState" : "42K04" |
| 696 | + }, |
639 | 697 | "PIPE_FUNCTION_EXITED" : { |
640 | 698 | "message" : [ |
641 | 699 | "Pipe function `<func_name>` exited with error code <error_code>." |
|
797 | 855 | "Unknown response: <response>." |
798 | 856 | ] |
799 | 857 | }, |
| 858 | + "UNRESOLVED_COLUMN" : { |
| 859 | + "message" : [ |
| 860 | + "A column, variable, or function parameter with name <objectName> cannot be resolved." |
| 861 | + ], |
| 862 | + "sub_class" : { |
| 863 | + "WITHOUT_SUGGESTION" : { |
| 864 | + "message" : [ |
| 865 | + "" |
| 866 | + ] |
| 867 | + }, |
| 868 | + "WITH_SUGGESTION" : { |
| 869 | + "message" : [ |
| 870 | + "Did you mean one of the following? [<proposal>]." |
| 871 | + ] |
| 872 | + } |
| 873 | + }, |
| 874 | + "sqlState" : "42703" |
| 875 | + }, |
| 876 | + "UNRESOLVED_COLUMN_AMONG_FIELD_NAMES" : { |
| 877 | + "message" : [ |
| 878 | + "Cannot resolve column name \\"<colName>\\" among (<fieldNames>)." |
| 879 | + ], |
| 880 | + "sqlState" : "42703" |
| 881 | + }, |
800 | 882 | "UNSUPPORTED_DATA_TYPE" : { |
801 | 883 | "message" : [ |
802 | 884 | "Unsupported DataType `<data_type>`." |
803 | 885 | ] |
804 | 886 | }, |
| 887 | + "UNSUPPORTED_DATATYPE" : { |
| 888 | + "message" : [ |
| 889 | + "Unsupported data type <typeName>." |
| 890 | + ], |
| 891 | + "sqlState" : "0A000" |
| 892 | + }, |
805 | 893 | "UNSUPPORTED_DATA_TYPE_FOR_ARROW" : { |
806 | 894 | "message" : [ |
807 | 895 | "Single data type <data_type> is not supported with Arrow." |
|
817 | 905 | "<data_type> is only supported with pyarrow 2.0.0 and above." |
818 | 906 | ] |
819 | 907 | }, |
| 908 | + "UNSUPPORTED_DATA_TYPE_FOR_DATASOURCE" : { |
| 909 | + "message" : [ |
| 910 | + "The <format> datasource doesn't support the column <columnName> of the type <columnType>." |
| 911 | + ], |
| 912 | + "sqlState" : "0A000" |
| 913 | + }, |
| 914 | + "UNSUPPORTED_FEATURE" : { |
| 915 | + "message" : [ |
| 916 | + "The feature is not supported:" |
| 917 | + ], |
| 918 | + "sub_class" : { |
| 919 | + "SET_OPERATION_ON_MAP_TYPE" : { |
| 920 | + "message" : [ |
| 921 | + "Cannot have MAP type columns in DataFrame which calls set operations (INTERSECT, EXCEPT, etc.), but the type of column <colName> is <dataType>." |
| 922 | + ] |
| 923 | + } |
| 924 | + }, |
| 925 | + "sqlState" : "0A000" |
| 926 | + }, |
820 | 927 | "UNSUPPORTED_JOIN_TYPE" : { |
821 | 928 | "message" : [ |
822 | 929 | "Unsupported join type: <join_type>. Supported join types include: \\"inner\\", \\"outer\\", \\"full\\", \\"fullouter\\", \\"full_outer\\", \\"leftouter\\", \\"left\\", \\"left_outer\\", \\"rightouter\\", \\"right\\", \\"right_outer\\", \\"leftsemi\\", \\"left_semi\\", \\"semi\\", \\"leftanti\\", \\"left_anti\\", \\"anti\\", \\"cross\\"." |
|
911 | 1018 | "message": [ |
912 | 1019 | "Index must be non-zero." |
913 | 1020 | ] |
| 1021 | + }, |
| 1022 | + "_LEGACY_ERROR_TEMP_1323" : { |
| 1023 | + "message" : [ |
| 1024 | + "\\"<colName>\\" is not a numeric column. Aggregation function can only be applied on a numeric column." |
| 1025 | + ] |
914 | 1026 | } |
915 | 1027 | } |
916 | 1028 | """ |
|
0 commit comments