diff --git a/be/src/exec/text_converter.hpp b/be/src/exec/text_converter.hpp index 44e807ced02875..3b885348234591 100644 --- a/be/src/exec/text_converter.hpp +++ b/be/src/exec/text_converter.hpp @@ -41,7 +41,7 @@ namespace doris { inline bool TextConverter::write_slot(const SlotDescriptor* slot_desc, Tuple* tuple, const char* data, int len, bool copy_string, bool need_escape, MemPool* pool) { - //小批量导入只有\N被认为是NULL,没有批量导入的replace_value函数 + //Small batch import only \N is considered to be NULL, there is no replace_value function for batch import if (true == slot_desc->is_nullable()) { if (len == 2 && data[0] == '\\' && data[1] == 'N') { tuple->set_null(slot_desc->null_indicator_offset()); diff --git a/docs/en/administrator-guide/http-actions/fe/table-schema-action.md b/docs/en/administrator-guide/http-actions/fe/table-schema-action.md index e0a83374932b9e..d89de1b9d98bc2 100644 --- a/docs/en/administrator-guide/http-actions/fe/table-schema-action.md +++ b/docs/en/administrator-guide/http-actions/fe/table-schema-action.md @@ -53,7 +53,7 @@ None None ## Response - +* The http interface returns as follows: ``` { "msg": "success", @@ -76,10 +76,59 @@ None "count": 0 } ``` - +* The http v2 interface returns as follows: +``` +{ + "msg": "success", + "code": 0, + "data": { + "properties": [{ + "type": "INT", + "name": "k1", + "comment": "" + }, { + "type": "INT", + "name": "k2", + "comment": "" + }], + "keysType":UNIQUE_KEYS, + "status": 200 + }, + "count": 0 +} +``` +Note: The difference is that the `http` method returns more `aggregation_type` fields than the `http v2` method. The `http v2` is enabled by setting `enable_http_server_v2`. For detailed parameter descriptions, see [fe parameter settings](https://doris.apache.org/administrator-guide/config/fe_config.html) + ## Examples -1. Get the table structure information of the specified table. +1. Get the table structure information of the specified table via http interface. + + ``` + GET /api/db1/tbl1/_schema + + Response: + { + "msg": "success", + "code": 0, + "data": { + "properties": [{ + "type": "INT", + "name": "k1", + "comment": "", + "aggregation_type":"" + }, { + "type": "INT", + "name": "k2", + "comment": "", + "aggregation_type":"MAX" + }], + "keysType":UNIQUE_KEYS, + "status": 200 + }, + "count": 0 + } + ``` +2. Get the table structure information of the specified table via http v2 interface. ``` GET /api/db1/tbl1/_schema @@ -103,4 +152,4 @@ None }, "count": 0 } - ``` + ``` \ No newline at end of file diff --git a/docs/zh-CN/administrator-guide/http-actions/fe/table-schema-action.md b/docs/zh-CN/administrator-guide/http-actions/fe/table-schema-action.md index c978c6bcb0fb16..0d3ee704ff3732 100644 --- a/docs/zh-CN/administrator-guide/http-actions/fe/table-schema-action.md +++ b/docs/zh-CN/administrator-guide/http-actions/fe/table-schema-action.md @@ -53,7 +53,7 @@ under the License. 无 ## Response - +* http接口返回如下: ``` { "msg": "success", @@ -76,10 +76,59 @@ under the License. "count": 0 } ``` - +* http v2接口返回如下: +``` +{ + "msg": "success", + "code": 0, + "data": { + "properties": [{ + "type": "INT", + "name": "k1", + "comment": "" + }, { + "type": "INT", + "name": "k2", + "comment": "" + }], + "keysType":UNIQUE_KEYS, + "status": 200 + }, + "count": 0 +} +``` +注意:区别为`http`方式比`http v2`方式多返回`aggregation_type`字段,`http v2`开启是通过`enable_http_server_v2`进行设置,具体参数说明详见[fe参数设置](https://doris.apache.org/zh-CN/administrator-guide/config/fe_config.html) + ## Examples -1. 获取指定表的表结构信息。 +1. 通过http获取指定表的表结构信息。 + + ``` + GET /api/db1/tbl1/_schema + + Response: + { + "msg": "success", + "code": 0, + "data": { + "properties": [{ + "type": "INT", + "name": "k1", + "comment": "", + "aggregation_type":"" + }, { + "type": "INT", + "name": "k2", + "comment": "", + "aggregation_type":"MAX" + }], + "keysType":UNIQUE_KEYS, + "status": 200 + }, + "count": 0 + } + ``` +2. 通过http v2获取指定表的表结构信息。 ``` GET /api/db1/tbl1/_schema @@ -103,4 +152,4 @@ under the License. }, "count": 0 } - ``` + ``` diff --git a/docs/zh-CN/faq/error.md b/docs/zh-CN/faq/error.md index 705e9528a582ce..fea200c496f26e 100644 --- a/docs/zh-CN/faq/error.md +++ b/docs/zh-CN/faq/error.md @@ -127,7 +127,7 @@ failed to initialize storage reader. tablet=63416.1050661139.aa4d304e7a7aff9c-f0 在导入或者查询时,我们可能遇到这个错误。如果你去对应的 BE 日志中查看,也可能会找到类似错误。 -这是一个 RPC 错误,通常由两种可能:1. 对应的 BE 节点宕机。2. rpc 拥塞或其他错误。 +这是一个 RPC 错误,通常有两种可能:1. 对应的 BE 节点宕机。2. rpc 拥塞或其他错误。 如果是 BE 节点宕机,则需要查看具体的宕机原因。这里只讨论 rpc 拥塞的问题。