Updated on 2022-09-15 GMT+08:00

Querying Dimension Tables

Function

This API is used to query dimension tables based on the name, creator, approver, status, and modification time and display the results on different pages.

URI

GET /v2/{project_id}/design/dimension-logic-tables

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

name

No

String

Fuzzy query by name or code

create_by

No

String

Creator

approver

No

String

Approver

owner

No

String

Query by owner

status

No

String

Business status

Enumeration values:

  • DRAFT

  • PUBLISH_DEVELOPING

  • PUBLISHED

  • OFFLINE_DEVELOPING

  • OFFLINE

  • REJECT

sync_status

No

String

Enumeration values:

  • RUNNING

  • NO_NEED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

sync_key

No

Array

Enumeration values:

  • BUSINESS_ASSET

  • DATA_QUALITY

  • TECHNICAL_ASSET

  • META_DATA_LINK

  • PHYSICAL_TABLE

  • DLF_TASK

  • MATERIALIZATION

l2_id

No

Long

ID of subject area l2

dimension_id

No

Long

Parameters for querying dimension attributes based on the dimension ID

begin_time

No

String

Left boundary for a time filter. This parameter must be used together with end_time.

end_time

No

String

Right boundary for a time filter. This parameter must be used together with begin_time.

limit

No

Integer

Number of records to be queried, that is, Y records. The value ranges from 1 to 100. The default value is 50.

Maximum: 100

Default: 50

offset

No

Integer

Query offset, that is, X data records are skipped. The value must be 0 or an integer multiple of limit. If the value does not meet the requirements, it will be rounded down. The default value is 0.

Default: 0

biz_catalog_id

No

String

Business catalog ID

dimension_type

No

String

Dimension type

Enumeration values:

  • COMMON

  • LOOKUP

  • HIERARCHIES

Request Parameters

None

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

id

String

Table ID

tb_name

String

Table name

Maximum: 600

tb_logic_name

String

Logical entity name

Maximum: 200

l1_id

Long

Subject area group ID

l2_id

String

Subject area ID

l3_id

Long

Business object ID

create_by

String

Creator

description

String

Description

Maximum: 600

dimension_id

Long

Dimension ID

owner

String

Asset owner

dimension_type

String

Dimension type

Default: COMMON

Enumeration values:

  • COMMON

  • LOOKUP

  • HIERARCHIES

code_table_id

Long

Lookup table ID

code_table

CodeTableVO object

Lookup table

queue_name

String

Queue required for a DLI data connection to execute SQL statements. This parameter is mandatory for DLI data connections.

dw_id

String

Data connection ID

reversed

Boolean

Whether the table is reversed

Default: false

partition_conf

String

Partition expression

dirty_out_switch

Boolean

Whether to export dirty data

Default: false

dirty_out_database

String

Database to which dirty data will be exported

dirty_out_prefix

String

Prefix of an abnormal table

dirty_out_suffix

String

Suffix of an abnormal table

db_name

String

Database name

tb_id

String

Data table ID

schema

String

Schema, which is required for DWS

table_type

String

Table type

status

String

Business statuses

Enumeration values:

  • DRAFT

  • PUBLISH_DEVELOPING

  • PUBLISHED

  • OFFLINE_DEVELOPING

  • OFFLINE

  • REJECT

tb_guid

String

GUID of the physical table corresponding to the published table

tb_logic_guid

String

GUID of the logical entity corresponding to the published table

dimension_name

String

Dimension name

attributes

Array of DimensionLogicTableAttributeVO objects

Attributes

dw_type

String

Data connection type

dw_name

String

Data connection name

l1

String

Chinese name of the subject area group

l2

String

Chinese name of the subject area

l3

String

Chinese name of the business object

create_time

String

Creation time

update_time

String

Update time

approval_info

ApprovalVO object

Approval information

new_biz

BizVersionManageVO object

Business version management

physical_table

String

Table creation status

Enumeration values:

  • NO_NEED

  • CREATE_SUCCESS

  • CREATE_FAILED

  • UPDATE_SUCCESS

  • UPDATE_FAILED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

  • RUNNING

  • OFFLINE

technical_asset

String

Technical asset synchronization status

Enumeration values:

  • NO_NEED

  • CREATE_SUCCESS

  • CREATE_FAILED

  • UPDATE_SUCCESS

  • UPDATE_FAILED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

  • RUNNING

  • OFFLINE

business_asset

String

Logical asset synchronization status

Enumeration values:

  • NO_NEED

  • CREATE_SUCCESS

  • CREATE_FAILED

  • UPDATE_SUCCESS

  • UPDATE_FAILED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

  • RUNNING

  • OFFLINE

meta_data_link

String

Asset association status

Enumeration values:

  • NO_NEED

  • CREATE_SUCCESS

  • CREATE_FAILED

  • UPDATE_SUCCESS

  • UPDATE_FAILED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

  • RUNNING

  • OFFLINE

data_quality

String

Quality job status

Enumeration values:

  • NO_NEED

  • CREATE_SUCCESS

  • CREATE_FAILED

  • UPDATE_SUCCESS

  • UPDATE_FAILED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

  • RUNNING

  • OFFLINE

materialization

String

Storage status of the value

Enumeration values:

  • NO_NEED

  • CREATE_SUCCESS

  • CREATE_FAILED

  • UPDATE_SUCCESS

  • UPDATE_FAILED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

  • RUNNING

  • OFFLINE

summary_status

String

Overall synchronization status

Enumeration values:

  • NO_NEED

  • CREATE_SUCCESS

  • CREATE_FAILED

  • UPDATE_SUCCESS

  • UPDATE_FAILED

  • SUMMARY_SUCCESS

  • SUMMARY_FAILED

  • RUNNING

  • OFFLINE

distribute

String

DISTRIBUTE BY [HASH(column)|REPLICATION]

Enumeration values:

  • HASH

  • REPLICATION

distribute_column

String

DISTRIBUTE BY HASH column

quality_id

Long

Quality ID

alias

String

Alias

self_defined_fields

Array of SelfDefinedFieldVO objects

Custom fields

Table 4 CodeTableVO

Parameter

Type

Description

id

Long

ID

name_en

String

Table name in English

Maximum: 200

name_ch

String

Table name in Chinese

Maximum: 200

tb_version

Integer

Table version

directory_id

Long

Catalog ID

directory_path

String

Catalog tree

description

String

Description

Maximum: 600

create_by

String

Creator

status

String

Business statuses

Enumeration values:

  • DRAFT

  • PUBLISH_DEVELOPING

  • PUBLISHED

  • OFFLINE_DEVELOPING

  • OFFLINE

  • REJECT

create_time

String

Creation time

update_time

String

Update time

approval_info

ApprovalVO object

Approval information

new_biz

BizVersionManageVO object

Business version management

code_table_fields

Array of CodeTableFieldVO objects

Lookup table attribute information

Table 5 ApprovalVO

Parameter

Type

Description

id

Long

ID

tenant_id

String

tenant id

name_ch

String

Approval name in Chinese

name_en

String

Approval name in English

biz_id

Long

Business ID

biz_type

String

Business types

Enumeration values:

  • ATOMIC_INDEX

  • DERIVATIVE_INDEX

  • DIMENSION

  • DIMENSION_ATTRIBUTE

  • DIMENSION_HIERARCHIES

  • CONDITION_GROUP

  • TIME_CONDITION

  • COMMON_CONDITION

  • FACT_LOGIC_TABLE

  • TABLE_MODEL

  • DIMENSION_LOGIC_TABLE

  • STANDARD_ELEMENT

  • AGGREGATION_LOGIC_TABLE

  • TAG

  • CODE_TABLE

  • TABLE_MODEL_ATTRIBUTE

  • FACT_DIMENSION

  • FACT_ATTRIBUTE

  • FACT_MEASURE

  • SUMMARY_DIMENSION_ATTRIBUTE

  • SUMMARY_TIME

  • DIMENSION_TABLE_ATTRIBUTE

  • QUALITY_RULE

  • BIZ_METRIC

  • COMPOUND_METRIC

  • INFO_ARCH

  • DEGENERATE_DIMENSION

  • TABLE_MODEL_LOGIC

biz_info

String

Business information

biz_info_obj

Object

Business information object

biz_version

Integer

Business version

biz_status

String

Business statuses

Enumeration values:

  • DRAFT

  • PUBLISH_DEVELOPING

  • PUBLISHED

  • OFFLINE_DEVELOPING

  • OFFLINE

  • REJECT

approval_status

String

Approval statuses

Enumeration values:

  • DEVELOPING

  • APPROVED

  • REJECT

  • WITHDREW

approval_type

String

Approval types

Enumeration values:

  • PUBLISH

  • OFFLINE

submit_time

String

Submission time

create_by

String

Creator

l1

String

Subject area group

l2

String

Subject area

l3

String

Business object

approval_time

String

Approval time

approver

String

Approver

email

String

Approver email address

msg

String

Approval message

directory_path

String

Directory tree

Table 6 BizVersionManageVO

Parameter

Type

Description

id

Long

ID information

biz_type

String

Business types

Enumeration values:

  • ATOMIC_INDEX

  • DERIVATIVE_INDEX

  • DIMENSION

  • DIMENSION_ATTRIBUTE

  • DIMENSION_HIERARCHIES

  • CONDITION_GROUP

  • TIME_CONDITION

  • COMMON_CONDITION

  • FACT_LOGIC_TABLE

  • TABLE_MODEL

  • DIMENSION_LOGIC_TABLE

  • STANDARD_ELEMENT

  • AGGREGATION_LOGIC_TABLE

  • TAG

  • CODE_TABLE

  • TABLE_MODEL_ATTRIBUTE

  • FACT_DIMENSION

  • FACT_ATTRIBUTE

  • FACT_MEASURE

  • SUMMARY_DIMENSION_ATTRIBUTE

  • SUMMARY_TIME

  • DIMENSION_TABLE_ATTRIBUTE

  • QUALITY_RULE

  • BIZ_METRIC

  • COMPOUND_METRIC

  • INFO_ARCH

  • DEGENERATE_DIMENSION

  • TABLE_MODEL_LOGIC

biz_id

Long

Business ID

biz_info

String

Business object information

status

String

Business statuses

Enumeration values:

  • DRAFT

  • PUBLISH_DEVELOPING

  • PUBLISHED

  • OFFLINE_DEVELOPING

  • OFFLINE

  • REJECT

biz_version

Integer

Business version

create_time

String

Creation time

update_time

String

Update time

Table 7 CodeTableFieldVO

Parameter

Type

Description

id

Long

ID

code_table_id

Long

Lookup table ID

ordinal

Integer

Ordinal

name_en

String

Field name in English

Maximum: 600

name_ch

String

Field name in Chinese

Maximum: 200

description

String

Description

Maximum: 600

data_type

String

Data type

domain_type

String

Data type domains

Enumeration values:

  • NUMBER

  • STRING

  • DATETIME

  • BLOB

  • OTHER

data_type_extend

String

Data type extended field

Maximum: 50

is_unique_key

Boolean

Whether the attribute is unique

Default: false

code_table_field_values

Array of CodeTableFieldValueVO objects

Lookup table attribute value

count_field_values

Integer

Number of lookup table attribute values

Table 8 CodeTableFieldValueVO

Parameter

Type

Description

id

Long

ID

fd_id

Long

Lookup table attribute ID

fd_value

String

Lookup table attribute value

ordinal

Integer

Ordinal

description

String

Description

Maximum: 600

Table 9 DimensionLogicTableAttributeVO

Parameter

Type

Description

id

Long

id

dimension_logic_table_id

String

Dimension table ID

ordinal

Integer

Ordinal

dimension_attribute_id

Long

Dimension attribute ID

name_en

String

Dimension table attribute name in English

name_ch

String

Dimension table attribute name in Chinese

description

String

Description

data_type

String

Data type

domain_type

String

Data type domains

Enumeration values:

  • NUMBER

  • STRING

  • DATETIME

  • BLOB

  • OTHER

data_type_extend

String

Data type extended field

Maximum: 50

is_primary_key

Boolean

Whether the attribute is a primary key

Default: false

is_biz_primary

Boolean

Whether the attribute is a business primary key

Default: false

is_partition_key

Boolean

Whether the attribute is a partition key

Default: false

not_null

Boolean

Whether the attribute is not null

Default: false

stand_row_id

Long

ID of the associated data standard

stand_row_name

String

Maximum: 600

quality_infos

Array of QualityInfoVO objects

Quality information

alias

String

Alias

self_defined_fields

Array of SelfDefinedFieldVO objects

Custom fields

Table 10 QualityInfoVO

Parameter

Type

Description

id

Long

ID

table_id

Long

Table ID

attr_id

Long

Attribute ID

biz_type

String

Business types

Enumeration values:

  • ATOMIC_INDEX

  • DERIVATIVE_INDEX

  • DIMENSION

  • DIMENSION_ATTRIBUTE

  • DIMENSION_HIERARCHIES

  • CONDITION_GROUP

  • TIME_CONDITION

  • COMMON_CONDITION

  • FACT_LOGIC_TABLE

  • TABLE_MODEL

  • DIMENSION_LOGIC_TABLE

  • STANDARD_ELEMENT

  • AGGREGATION_LOGIC_TABLE

  • TAG

  • CODE_TABLE

  • TABLE_MODEL_ATTRIBUTE

  • FACT_DIMENSION

  • FACT_ATTRIBUTE

  • FACT_MEASURE

  • SUMMARY_DIMENSION_ATTRIBUTE

  • SUMMARY_TIME

  • DIMENSION_TABLE_ATTRIBUTE

  • QUALITY_RULE

  • BIZ_METRIC

  • COMPOUND_METRIC

  • INFO_ARCH

  • DEGENERATE_DIMENSION

  • TABLE_MODEL_LOGIC

data_quality_id

Long

Quality ID

show_control

Integer

Whether to display the regular expression

data_quality_name

String

Quality name

alert_conf

String

Alarm configuration

expression

String

Regular expression in verification rules

extend_info

String

Extended information

from_standard

Boolean

Whether the quality information is from data standard quality configuration

Default: false

result_description

String

Result description

create_by

String

Creator

update_by

String

User who updated the quality information

create_time

String

Creation time

update_time

String

Update time

Table 11 SelfDefinedFieldVO

Parameter

Type

Description

fd_name_ch

String

Custom field name in Chinese

Maximum: 200

fd_name_en

String

Custom field name in English

Maximum: 200

not_null

Boolean

Whether the field is mandatory

fd_value

String

Field value

Status code: 400

Table 12 Response body parameters

Parameter

Type

Description

error_code

String

Error code, for example, DS.000 which indicates that the request was successfully processed.

error_msg

String

Error message

data

Object

Returned data

Status code: 401

Table 13 Response body parameters

Parameter

Type

Description

error_code

String

Error code, for example, DS.000 which indicates that the request was successfully processed.

error_msg

String

Error message

data

Object

Returned data

Status code: 403

Table 14 Response body parameters

Parameter

Type

Description

error_code

String

Error code, for example, DS.000 which indicates that the request was successfully processed.

error_msg

String

Error message

data

Object

Returned data

Example Requests

None

Example Responses

Status code: 200

The operation succeeds. The DimensionLogicTableVO array and the total number of dimension tables are returned.

{
  "id" : "873258132317642752",
  "tb_name" : "dim_vendor",
  "tb_logic_name" : "Vendor",
  "l1_id" : "873232498044411904",
  "l2_id" : "873232798230675456",
  "l3_id" : "873233599258927104",
  "create_by" : "abc",
  "description" : "None",
  "dimension_id" : "873251051724242944",
  "owner" : "abc",
  "dimension_type" : "LOOKUP",
  "code_table_id" : "873235088123527168",
  "code_table" : null,
  "queue_name" : "dgc_dli_test",
  "dw_id" : "2c9080f07b03db8d017b198a4a20002f",
  "reversed" : null,
  "partition_conf" : null,
  "dirty_out_switch" : false,
  "dirty_out_database" : "",
  "dirty_out_prefix" : "",
  "dirty_out_suffix" : "",
  "db_name" : "demo_dwr_db",
  "tb_id" : "NativeTable-2c9080f07b03db8d017b198a4a20002f-demo_dwr_db-dim_vendor",
  "schema" : "",
  "table_type" : "MANAGED",
  "status" : "PUBLISHED",
  "tb_guid" : "cea79c27-446e-4529-86e7-d1b371ebb876",
  "tb_logic_guid" : "048cc0b7-3c0f-40cb-b0e9-e81261117f2d",
  "dimension_name" : "Vendor",
  "attributes" : [ {
    "id" : "873258132321837056",
    "dimension_logic_table_id" : "873258132317642752",
    "ordinal" : 1,
    "dimension_attribute_id" : "873251051732631552",
    "name_en" : "vendor_id",
    "name_ch" : "Vendor ID",
    "description" : "",
    "data_type" : "BIGINT",
    "domain_type" : "NUMBER",
    "data_type_extend" : null,
    "is_primary_key" : true,
    "is_biz_primary" : true,
    "is_partition_key" : false,
    "not_null" : true,
    "stand_row_id" : null,
    "stand_row_name" : null,
    "quality_infos" : null,
    "alias" : null,
    "self_defined_fields" : null
  }, {
    "id" : "873258132321837057",
    "dimension_logic_table_id" : "873258132317642752",
    "ordinal" : 2,
    "dimension_attribute_id" : "873251051732631553",
    "name_en" : "vendor_value",
    "name_ch" : "Vendor",
    "description" : "",
    "data_type" : "STRING",
    "domain_type" : "STRING",
    "data_type_extend" : null,
    "is_primary_key" : false,
    "is_biz_primary" : false,
    "is_partition_key" : false,
    "not_null" : false,
    "stand_row_id" : null,
    "stand_row_name" : null,
    "quality_infos" : null,
    "alias" : null,
    "self_defined_fields" : null
  } ],
  "dw_type" : "DLI",
  "dw_name" : null,
  "l1" : "City traffic",
  "l2" : "Corporation",
  "l3" : "Vendor",
  "create_time" : "2021-08-06T17:36:03+08:00",
  "update_time" : "2021-10-14T10:54:58+08:00",
  "approval_info" : {
    "id" : "873258129008336896",
    "tenant_id" : null,
    "name_ch" : null,
    "name_en" : null,
    "biz_id" : "873251051724242944",
    "biz_type" : null,
    "biz_info" : null,
    "biz_info_obj" : null,
    "biz_version" : 0,
    "biz_status" : "PUBLISHED",
    "approval_status" : "APPROVED",
    "approval_type" : null,
    "submit_time" : "2021-08-06T17:36:02+08:00",
    "create_by" : null,
    "l1" : null,
    "l2" : null,
    "l3" : null,
    "approval_time" : "2021-08-06T17:36:03+08:00",
    "approver" : "abc",
    "email" : null,
    "msg" : "Fast Approval OK.",
    "directory_path" : null
  },
  "new_biz" : null,
  "physical_table" : "CREATE_SUCCESS",
  "technical_asset" : "UPDATE_SUCCESS",
  "business_asset" : "UPDATE_SUCCESS",
  "meta_data_link" : "UPDATE_SUCCESS",
  "data_quality" : "UPDATE_SUCCESS",
  "materialization" : null,
  "summary_status" : "SUMMARY_SUCCESS",
  "distribute" : null,
  "distribute_column" : null,
  "quality_id" : "873258150667665409",
  "alias" : "",
  "self_defined_fields" : null
}

Status Codes

Status Code

Description

200

The operation succeeds. The DimensionLogicTableVO array and the total number of dimension tables are returned.

400

BadRequest

401

Unauthorized

403

Forbidden