mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-21 09:10:48 +00:00
3fb8d08dd4
This patch adds errorCode() function that will return macro name by the exception code, useful for analyzing query_log and similar. Later some descriptions can be added. v2: replace hana::map/fusion::vector with external script v3: - use binary cmake dir for .sh - use jump table over suboptimal std::unordered_map (with very poor hash function for int -- std::hash) - cleanup errorCodeToName (drop extra templates and headers) - rename errorCode -> errorCodeToName - fix arcadia build (by not providing those helpers there) - fix build on CI, by using CMAKE_CXX_COMPILER for parsing the file
4 lines
92 B
SQL
4 lines
92 B
SQL
SELECT errorCodeToName(toUInt32(-1));
|
|
SELECT errorCodeToName(0);
|
|
SELECT errorCodeToName(1);
|