主题
业务指标
资源说明
业务指标的定义
数据工程师面对分析师的需求,需要将业务数据库的数据集、字段整理创建成业务指标,供分析师以业务指标为基本单位进行数据下载和分析。
业务指标结构说明
Metric
下面是业务指标特有的结构说明
字段 | 类型 | 描述 |
---|---|---|
createdBy | LONG | 创建者的userId |
createdAt | DATE | 创建时间 |
updatedBy | LONG | 更新者的userId |
updatedAt | DATE | 更新时间 |
where | HE 数组 | 限定条件 |
dimensions | JSONOBJECT 数组 | 定义分析维度 |
pathAttr | METRIC 数组 | 路径归因 |
implication | STRING | 业务含义 |
category | STRING | 类别,默认值为"measure" |
MetricDto
字段 | 类型 | 描述 |
---|---|---|
creator | OBJECT | 创建者信息 |
updater | OBJECT | 更新者信息 |
action | STRING | 权限描述, admin-read-write是管理者权限,read-write是编辑者权限,read是查看者权限 |
接口说明
新增业务指标
请求URL
http
POST /api/apps/{appId}/datasets/{datasetId}/measures HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
request body 请求体
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 业务指标共同结构见业务指标结构说明 |
接口示例
http
POST /api/apps/119287/datasets/7/measures HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
// Request Body:
{
"label": "988test",
"implication": "",
"action": "write",
"appId": 119287,
"datasetId": 7,
"dimensions": [
{
"datasetId": 7,
"fieldName": "省/自治区",
"label": "省/自治区"
},
{
"datasetId": 7,
"fieldName": "城市",
"label": "城市"
}
],
"expr": {
"kind": "formula",
"op": "SUM({销售额})"
},
"pathAttr": [
]
}
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"msg": "success",
"data": {
"datasetId": 7,
"fieldName": "c1",
"appId": 119287,
"tags": {
},
"createdBy": 11549,
"createdAt": "2023-02-10 11:04:12",
"updatedBy": 11549,
"updatedAt": "2023-02-10 11:04:12",
"dimensions": [
{
"fieldName": "省/自治区",
"datasetId": 7,
"label": "省/自治区"
},
{
"fieldName": "城市",
"datasetId": 7,
"label": "城市"
}
],
"pathAttr": [
],
"implication": "",
"category": "measure",
"label": "988test",
"expr": {
"kind": "formula",
"op": "SUM({销售额})",
"type": "number",
"value": "SUM({销售额})",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": true
},
"type": "number",
"config": {
}
}
}
复制业务指标
请求URL
http
POST /api/apps/{appId}/datasets/{datasetId}/measures/{fieldName}/duplicate HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
request body 请求体
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
label | STRING | 是 | 别名 |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 业务指标共同结构见业务指标结构说明 |
接口示例
http
POST /api/apps/119287/datasets/7/measures/c1/duplicate HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
// Request Body:
{
"label": "988test1"
}
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"msg": "success",
"data": {
"datasetId": 7,
"fieldName": "c2",
"appId": 119287,
"tags": {
},
"createdBy": 11549,
"createdAt": "2023-02-10 11:08:42",
"updatedBy": 11549,
"updatedAt": "2023-02-10 11:08:42",
"dimensions": [
{
"fieldName": "省/自治区",
"datasetId": 7,
"label": "省/自治区"
},
{
"fieldName": "城市",
"datasetId": 7,
"label": "城市"
}
],
"pathAttr": [
],
"implication": "",
"category": "measure",
"label": "988test1",
"expr": {
"kind": "formula",
"op": "SUM({销售额})",
"type": "number",
"value": "SUM({销售额})",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": true
},
"type": "number",
"config": {
}
}
}
更新业务指标
请求URL
http
PUT /api/apps/{appId}/datasets/{datasetId}/measures/{fieldName} HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
request body 请求体
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
force | BOOLEAN | 否 | 是否强制更新数据集 |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 业务指标共同结构见业务指标结构说明 |
接口示例
http
PUT /api/apps/119287/datasets/7/measures/c1 HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
// Request Body:
{
"datasetId": 7,
"fieldName": "c1",
"appId": 119287,
"tags": {
},
"dimensions": [
{
"fieldName": "省/自治区",
"datasetId": 7,
"label": "省/自治区"
},
{
"fieldName": "城市",
"datasetId": 7,
"label": "城市"
}
],
"pathAttr": [
],
"implication": "",
"category": "measure",
"label": "988test",
"expr": {
"kind": "formula",
"op": "SUM({销售额})",
"type": "number",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": true
},
"type": "number",
"action": "admin|read|write||",
"config": {
}
}
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"msg": "success",
"data": {
"datasetId": 7,
"fieldName": "c1",
"appId": 119287,
"tags": {
},
"updatedBy": 11549,
"updatedAt": "2023-02-10 11:16:53",
"dimensions": [
{
"fieldName": "省/自治区",
"datasetId": 7,
"label": "省/自治区"
},
{
"fieldName": "城市",
"datasetId": 7,
"label": "城市"
}
],
"pathAttr": [
],
"implication": "",
"category": "measure",
"label": "988test",
"expr": {
"kind": "formula",
"op": "SUM({销售额})",
"type": "number",
"value": "SUM({销售额})",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": true
},
"type": "number",
"config": {
}
}
}
分页查询业务指标
请求URL
http
GET /api/apps/{appId}/datasets/{datasetId}/measures HTTP/1.1
Accept: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
orderBy | STRING | 否 | 排序字段 |
orderType | STRING | 否 | 排序类型 |
kanbanId | LONG | 否 | 看板Id |
queryDimensionType | BOOLEAN | 否 | 是否查询分析维度字段类型 |
q | STRING | 否 | 搜索条件 |
limit | INTEGER | 是 | 分页获取个数,默认是1000 |
offst | INTEGER | 是 | 分页偏移量,默认是0 |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT 数组 | 业务指标共同结构见业务指标结构说明 |
接口示例
http
GET /api/apps/0/datasets/0/measures?orderBy=updatedAt&orderType=desc&limit=1000&offset=0&q=988 HTTP/1.1
Accept: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"msg": "success",
"data": [
{
"datasetId": 7,
"fieldName": "c1",
"appId": 119287,
"tags": {
},
"createdBy": 11549,
"createdAt": "2023-02-10 11:04:12",
"updatedBy": 11549,
"updatedAt": "2023-02-10 11:16:53",
"dimensions": [
{
"fieldName": "省/自治区",
"datasetId": 7,
"label": "省/自治区",
"type": "string"
},
{
"fieldName": "城市",
"datasetId": 7,
"label": "城市",
"type": "string"
}
],
"pathAttr": [
],
"implication": "",
"category": "measure",
"label": "988test",
"expr": {
"kind": "formula",
"op": "SUM({销售额})",
"type": "number",
"value": "SUM({销售额})",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": true
},
"type": "number",
"creator": {
"id": 11549,
"name": "陈静",
"email": "111@qq.com",
"avatar": "",
"loginName": "chenjing"
},
"updater": {
"id": 11549,
"name": "陈静",
"email": "111@qq.com",
"avatar": "",
"loginName": "chenjing"
},
"action": "|admin|read|write|",
"accessCount": 4,
"lastAccessedAt": "2023-02-10 11:16:47",
"config": {
}
},
{
"datasetId": 7,
"fieldName": "c2",
"appId": 119287,
"tags": {
},
"createdBy": 11549,
"createdAt": "2023-02-10 11:08:42",
"updatedBy": 11549,
"updatedAt": "2023-02-10 11:08:42",
"dimensions": [
{
"fieldName": "省/自治区",
"datasetId": 7,
"label": "省/自治区",
"type": "string"
},
{
"fieldName": "城市",
"datasetId": 7,
"label": "城市",
"type": "string"
}
],
"pathAttr": [
],
"implication": "",
"category": "measure",
"label": "988test1",
"expr": {
"kind": "formula",
"op": "SUM({销售额})",
"type": "number",
"value": "SUM({销售额})",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": true
},
"type": "number",
"creator": {
"id": 11549,
"name": "陈静",
"email": "111@qq.com",
"avatar": "",
"loginName": "chenjing"
},
"updater": {
"id": 11549,
"name": "陈静",
"email": "111@qq.com",
"avatar": "",
"loginName": "chenjing"
},
"action": "|admin|read|write|",
"accessCount": 4,
"lastAccessedAt": "2023-02-10 11:16:47",
"config": {
}
}
],
"totalHits": 2,
"offset": 0
}
根据ID查询业务指标
请求URL
http
GET /api/apps/{appId}/datasets/{datasetId}/measures/{fieldName} HTTP/1.1
Accept: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 业务指标共同结构见业务指标结构说明 |
接口示例
http
GET /api/apps/119287/datasets/7/measures/c1 HTTP/1.1
Accept: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"msg": "success",
"data": {
"datasetId": 7,
"fieldName": "c1",
"appId": 119287,
"tags": {
},
"dimensions": [
{
"fieldName": "省/自治区",
"datasetId": 7,
"label": "省/自治区"
},
{
"fieldName": "城市",
"datasetId": 7,
"label": "城市"
}
],
"pathAttr": [
],
"implication": "",
"category": "measure",
"label": "988test",
"expr": {
"kind": "formula",
"op": "SUM({销售额})",
"type": "number",
"value": "SUM({销售额})",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": true
},
"type": "number",
"action": "admin|read|write||",
"config": {
}
}
}
重写业务指标表达式
请求URL
http
POST /api/apps/{appId}/datasets/{datasetId}/measures/rewrite-formula HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
request body 请求体
HE 表达式,详情参照HE 的数据集函数
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 业务指标共同结构见业务指标结构说明 |
接口示例
http
POST /api/apps/125615/datasets/3/measures/rewrite-formula HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
// Request Body:
{
"kind": "formula",
"op": "COUNT({{12}}.{客户类型}) FILTER (WHERE TRUNC_MONTH({发货日期}) < {{%v_month}} AND in({c10}, {{%多值动态地区}}))",
"type": "number",
"value": "COUNT({{客户}}.{客户类型}) FILTER (WHERE TRUNC_MONTH({发货日期}) < {{%v_month}} AND in({caseWhen}, {{%多值动态地区}}))",
"isAggregate": true,
"isConstant": false,
"allFieldsFromBaseDataset": false
}
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"msg": "success",
"data": {
"kind": "formula",
"op": "COUNT({{12}}.{客户类型}) FILTER (WHERE TRUNC_MONTH({发货日期}) < {{%v_month}} AND in({c10}, {{%多值动态地区}}))",
"value": "COUNT({{客户}}.{客户类型}) FILTER (WHERE TRUNC_MONTH({发货日期}) < {{%v_month}} AND in({caseWhen}, {{%多值动态地区}}))",
"isAggregate": true
}
}
根据ID删除业务指标
请求URL
http
DELETE /api/apps/{appId}/datasets/{datasetId}/measures/{fieldName} HTTP/1.1
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
force | BOOLEAN | 否 | 是否强制更新数据集 |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
msg | STRING | 成功返回 success |
接口示例
http
DELETE /api/apps/119287/datasets/7/measures/c2 HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"msg": "success"
}
把指标添加到主题域的目录中
请求URL
http
POST /api/folders/{folderId}/metric-folders HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
folderId | INTEGER | 是 | 文件夹的 id |
request body 请求体
指标和文件夹对应关系的数组,数组的元素是描述关系的实体,下面是实体的字段信息:
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
appId | INTEGER | 是 | 指标所在的应用 id |
datasetId | INTEGER | 是 | 指标所在的数据集 id |
fieldName | STRING | 是 | 指标的字段名 |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
msg | STRING | 成功返回 success |
接口示例
http
POST /api/folders/109/metric-folders HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
// Request Body:
[
{
"appId": 2471,
"datasetId": 1,
"fieldName": "c1"
},
{
"appId": 2471,
"datasetId": 1,
"fieldName": "c0"
}
]
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"data": 2,
"msg": "success"
}
从主题域的目录中删除指标
请求URL
http
POST /api/folders/{folderId}/metric-folders/remove HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
folderId | INTEGER | 是 | 文件夹的 id |
request body 请求体
指标和文件夹对应关系的数组,数组的元素是描述关系的实体,下面是实体的字段信息:
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
appId | INTEGER | 是 | 指标所在的应用 id |
datasetId | INTEGER | 是 | 指标所在的数据集 id |
fieldName | STRING | 是 | 指标的字段名 |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
msg | STRING | 成功返回 success |
接口示例
http
POST /api/folders/109/metric-folders/remove HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
// Request Body:
[
{
"appId": 2471,
"datasetId": 1,
"fieldName": "c1"
}
]
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"data": 1,
"msg": "success"
}
切换主题域中指标上线、下线
请求URL
http
POST /api/folders/{folderId}/metric-folders/switch HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
folderId | INTEGER | 是 | 主题域的 id |
request body 请求体
指标和文件夹对应关系的数组,数组的元素是描述关系的实体,下面是实体的字段信息:
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
appId | INTEGER | 是 | 指标所在的应用 id |
datasetId | INTEGER | 是 | 指标所在的数据集 id |
fieldName | STRING | 是 | 指标的字段名 |
isOnline | BOOL | 是 | true 表示上线,false 表示下线 |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
msg | STRING | 成功返回 success |
接口示例
http
POST /api/folders/109/metric-folders/switch HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
// Request Body:
[
{
"appId": 2471,
"datasetId": 1,
"fieldName": "c1",
"isOnline": "false"
}
]
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "version@9a5e106#6730f0d",
"code": 0,
"data": 1,
"msg": "success"
}
主题域中指标的血缘关系
请求URL
http
GET /api/folders/{folderId}/measures/{measureId}/lineage HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
folderId | INTEGER | 是 | 主题域的 id |
measureId | INTEGER | 是 | 指标的 id |
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 见数据集血缘结构说明 |
接口示例
http
GET /api/folders/22/measures/10786/lineage HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"code": 0,
"msg": "success",
"data": {
"lineageGraph": {
"vertices": [
{
"vertexId": 0,
"appId": 750,
"datasetId": 7,
"title": "多表联合_A left join B ",
"refreshAt": "2025-01-09 09:54:09",
"type": "measure",
"fieldName": "m2",
"fieldLabel": "m2-0109-data-api",
"importType": 0
},
{
"vertexId": 1,
"appId": 750,
"datasetId": 7,
"title": "多表联合_A left join B ",
"type": "field",
"fieldName": "部门成立日期_2",
"fieldLabel": "部门成立日期",
"importType": 0
},
{
"vertexId": 2,
"appId": 750,
"datasetId": 7,
"title": "多表联合_A left join B ",
"type": "field",
"fieldName": "业绩金额_2",
"fieldLabel": "业绩金额",
"importType": 0
}
],
"edges": [
{
"left": 1,
"right": 0,
"lineageType": [
"FILTER"
]
},
{
"left": 2,
"right": 0,
"lineageType": [
"FORMULA"
]
}
]
}
}
}
获取主题域中指标的数据
请求URL
http
GET /api/folders/{folderId}/measures/{measureId}/data HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
folderId | INTEGER | 是 | 主题域的 id |
measureId | INTEGER | 是 | 指标的 id |
withAllDims | BOOLEAN | 否 | 是否需要业务指标定义的所有分析维度,默认为 false |
withAllDims 为 false,会根据业务指标的默认图表返回数据;withAllDims 为true,会根据业务指标配置的所有分析维度返回数据。
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 见数据集数据 datasetResultDto |
接口示例
http
GET /api/folders/22/measures/10786/data HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"code": 0,
"msg": "success",
"data": {
"data": [
[
"人力资源部",
4377
],
[
"财务部",
22581
]
],
"pagable": true,
"importSwitchable": true,
"schema": [
{
"fieldName": "部门_1_0",
"type": "string"
},
{
"fieldName": "2_1",
"type": "number"
}
],
"lastQueryTime": "2025-01-09T09:54:17.672455"
}
}
获取主题域中指标的 sql
请求URL
http
GET /api/folders/{folderId}/measures/{measureId}/sql-debug HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
请求参数
URL 参数
字段 | 类型 | 是否必须 | 说明 |
---|---|---|---|
folderId | INTEGER | 是 | 主题域的 id |
measureId | INTEGER | 是 | 指标的 id |
withAllDims | BOOLEAN | 否 | 是否需要业务指标定义的所有分析维度,默认为 false |
withAllDims 为 false,会根据业务指标的默认图表返回 sql;withAllDims 为true,会根据业务指标配置的所有分析维度返回 sql。
返回对象的格式说明
字段 | 类型 | 说明 |
---|---|---|
version | STRING | 当前系统版本哈希值 |
data | OBJECT | 字符串数组 |
接口示例
http
GET /api/folders/22/measures/10786/sql-debug HTTP/1.1
Content-Type: application/json
Cookie: csrf=183f1c4...; sid=26ee552d...; _USER_SESSION_ID=f2a01083...
http
HTTP/1.1 200 Ok
Content-Type: application/json
{
"version": "5.4-SNAPSHOT@@git.commit.id.abbrev@#b1e1b9e",
"code": 0,
"msg": "success",
"data": [
"SELECT `dataset_7`.`部门_1` AS `部门_1_0`, `dataset_7`.`子部门_1` AS `子部门_1_1`, `dataset_7`.`部门_2` AS `部门_2_2`, sum(`dataset_7`.`业绩金额_2`) AS `m2_3` FROM (SELECT `01JE553G57QSXQXR9F58NBERR4`.`部门` AS `部门_1`, `01JE553G57QSXQXR9F58NBERR4`.`子部门` AS `子部门_1`, `01JE553HYD9CWBQ8A8JCPW8X89`.`部门` AS `部门_2`, `01JE553HYD9CWBQ8A8JCPW8X89`.`业绩金额` AS `业绩金额_2` FROM (SELECT * FROM `kuangjiashuai`.`A` `dataset_1` WHERE `dataset_1`.`部门` != '销售部') `01JE553G57QSXQXR9F58NBERR4` LEFT JOIN (SELECT * FROM `kuangjiashuai`.`B` `dataset_2` WHERE `dataset_2`.`部门` != '{{%部门参数}}' AND `dataset_2`.`部门` != '市场部' AND year(`dataset_2`.`部门成立日期`) IN (2017, 2018, 2019)) `01JE553HYD9CWBQ8A8JCPW8X89` ON `01JE553G57QSXQXR9F58NBERR4`.`部门` = `01JE553HYD9CWBQ8A8JCPW8X89`.`部门` WHERE `01JE553HYD9CWBQ8A8JCPW8X89`.`部门` != '市场部' AND year(`01JE553HYD9CWBQ8A8JCPW8X89`.`部门成立日期`) IN (2017, 2018, 2019)) `dataset_7` GROUP BY 1, 2, 3 ORDER BY isnull(`部门_1_0`), `部门_1_0` ASC, isnull(`子部门_1_1`), `子部门_1_1` ASC, isnull(`部门_2_2`), `部门_2_2` ASC LIMIT 1000"
]
}