All Products
Search
Document Center

DataWorks:QueryPublicModelEngine

Last Updated:Nov 27, 2023

Queries information about objects that are created in Data Modeling by using fast modeling language (FML) statements.

  • Each time you call this API operation, you must use FML statements to query information about objects that are created in Data Modeling.

  • The information about the objects can be queried by page, except for data layers, business processes, and data domains. You can add an offset to the end of an FML statement.

    The num LIMIT num statement specifies the offset when the information about the objects is queried, and the number of pages to return each time. The offset value must be a multiple of the number of pages.

  • A maximum of 1,000 entries can be returned each time you call this API operation.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter

Type

Required

Example

Description

Action

String

Yes

QueryPublicModelEngine

The operation that you want to perform. Set the value to QueryPublicModelEngine.

Text

String

Yes

show dim tables

The FML statement that is used to query information about objects that are created in Data Modeling. For more information, see Use FML statements to configure and manage data tables.

Only SHOW statements are supported.

ProjectId

String

Yes

1234

The DataWorks workspace ID. You can log on to the DataWorks console and go to the Workspace page to obtain the workspace ID.

Response parameters

Parameter

Type

Example

Description

RequestId

String

4CFB2DED-7D9B-4C42-B4AA-CFF4991DFFF4

The request ID. You can use the ID to troubleshoot issues.

ReturnValue

Array of Object

[{ "gmtModified": The time when the table was last modified,"code": "The name of the table","creatorId": "The ID of the user who creates the table","creatorName": "The name of the user who creates the table","modifierId": "The ID of the user who last modifies the table","gmtCreate": The time when the table was created,"type": The type of the table,"ownerId": "The owner ID","uuid": "The UUID of the table","businessUnitUuid": "The business unit ID","detailType": "The subtype of the table","ownerName": "The name of the owner","name": "The display name of the table","modifierName": "The name of the user who last modifies the table","businessProcessUuid": "The business process ID". }]

The returned information about the object.

Response description

FML statement used to query data layers

show layers;

Response parameters

Parameter

Type

Example

Description

code

String

dws

The code of the data layer.

englishName

String

dws

The name of the data layer.

name

String

DWS layer

The display name of the data layer.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

description

String

Description of the DWS layer

The description of the data layer.

uuid

String

obj-123456

The UUID of the data layer.

gmtCreate

TimeStamp

1644397025000

The time when the data layer was created.

gmtModified

TimeStamp

1644459965000

The time when the data layer was last modified.

creatorId

String

0123456

The ID of the user who creates the data layer.

creatorName

String

A, B, C, and D

The name of the user who creates the data layer.

modifierId

String

0123456

The ID of the user who last modifies the data layer.

modifierName

String

A, B, C, and D

The name of the user who last modifies the data layer.

FML statement used to query data domains

show domains;

Response parameters

Parameter

Type

Example

Description

code

String

member

The code of the data domain.

englishName

String

member

The name of the data domain.

name

String

Member

The display name of the data domain.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

businessUnitCode

String

bu-123456

The code of the business unit.

description

String

Description of the Member data domain

The description of the data domain.

uuid

String

obj-123456

The UUID of the data domain.

gmtCreate

TimeStamp

1644397025000

The time when the data domain was created.

gmtModified

TimeStamp

1644459965000

The time when the data domain was last modified.

creatorId

String

0123456

The ID of the user who creates the data domain.

creatorName

String

A, B, C, and D

The name of the user who creates the data domain.

modifierId

String

0123456

The ID of the user who last modifies the data domain.

modifierName

String

A, B, C, and D

The name of the user who last modifies the data domain.

FML statements used to query business processes

  • FML statement used to query business processes without configuring query conditions: show business_processes;

  • FML statement used to query a business process based on the code of the business process: show business_processes where code='bp-code';

  • FML statement used to query business processes based on the code of a data domain: show business_processes where data_domain='dm-code';

    Response parameters

Parameter

Type

Example

Description

code

String

bp-123456

The code of the business process.

englishName

String

pay

The name of the business process.

name

String

Payment

The display name of the business process.

dataDomainCode

String

trade

The code of the data domain to which the business process belongs.

dataDomainName

String

Transaction

The display name of the data domain to which the business process belongs.

dataDomainUuid

String

dm-123456

The UUID of the data domain to which the business process belongs.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

description

String

Payment

The description of the business process.

source

Integer

2

The source of the business process. Valid values:

1: indicates that the business process is created by the system.

2: indicates that the business process is created by a user.

uuid

String

obj-123456

The UUID of the business process.

gmtCreate

TimeStamp

1644397025000

The time when the business process was created.

gmtModified

TimeStamp

1644459965000

The time when the business process was last modified.

creatorId

String

creatorId

The ID of the user who creates the business process.

creatorName

String

A, B, C, and D

The name of the user who creates the business process.

modifierId

String

0123456

The ID of the user who last modifies the business process.

modifierName

String

A, B, C, and D

The name of the user who last modifies the business process.

FML statements used to query business categories

 show business_categories;
 show business_categories where code='code';
 show business_categories where keyword='keyword',
 show business_categories where uuid='uuid'   

Response parameters

Parameter

Type

Example

Description

categoryDetail

DirectoryDetailDTO

{"uuid": "cate_uuid", "code": "trd", "name": "Transaction"}

The details of the business category.

name

String

E-commerce

The name of the directory.

detailType

String

DICT

The type of the directory.

parentUuid

String

dy-123456

The UUID of the parent directory.

description

String

Description

The description of the directory.

code

String

ind

The code of the business category.

dataDomains

List

[{"uuid": "domain1", "code": "trd", "name": "Transaction data domain"}]

The data domains that are associated with the business category.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

businessUnitCode

String

bu-123456

The code of the business unit.

description

String

Description

The description of the directory.

categoryPath

String

tm.ind

The path of the business category.

FML statement used to query data marts

show markets;

Response parameters

Parameter

Type

Example

Description

categoryDetail

DirectoryDetailDTO

{"uuid": "cate_uuid", "code": "trd", "name": "Transaction"}

The details of the data mart.

name

String

E-commerce

The name of the directory.

detailType

String

DICT

The type of the directory.

parentUuid

String

dy-123456

The UUID of the parent directory.

description

String

Description

The description of the directory.

code

String

ind

The code of the business category.

subDetailType

String

common

The subtype of the directory.

auditDTOList

List

[{"baseId":"123","showName":"test"}]

The reviewers.

code

String

member

The code of the data mart.

englishName

String

member

The name of the data mart.

name

String

Member

The display name of the data mart.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

businessUnitCode

String

bu-123456

The code of the business unit.

description

String

Description of a data mart

The description of the data mart.

auditDTOList

List

[{"baseId":"123","showName":"test"}]

The reviewers.

categoryPath

String

tm.ind

The path of the business category.

FML statement used to query subject areas

show subjects;

Response parameters

Parameter

Type

Example

Description

categoryDetail

DirectoryDetailDTO

{"uuid": "cate_uuid", "code": "trd", "name": "Transaction"}

The details of the subject area.

name

String

E-commerce

The name of the directory.

detailType

String

DICT

The type of the directory.

parentUuid

String

dy-123456

The UUID of the parent directory.

description

String

Description

The description of the directory.

code

String

ind

The code of the business category.

subDetailType

String

common

The subtype of the directory.

auditDTOList

List

[{"baseId":"123","showName":"test"}]

The reviewers.

code

String

member

The code of the data domain.

englishName

String

member

The name of the data domain.

name

String

Member

The display name of the data domain.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

businessUnitCode

String

bu-123456

The code of the business unit.

description

String

Description of the Member subject area

The description of the subject area.

auditDTOList

List

[{"baseId":"123","showName":"test"}]

The reviewers.

categoryPath

String

tm.ind

The path of the business category.

FML statement used to query data standard sets

show dict groups;

Response parameters

Parameter

Type

Example

Description

name

String

E-commerce

The name of the directory.

detailType

String

DICT

The type of the directory.

parentUuid

String

dy-123456

The UUID of the parent directory.

description

String

Description

The description of the directory.

code

String

ind

The code of the business category.

uuid

List

obj-123456

The UUID of the data standard set.

gmtCreate

TimeStamp

1644397025000

The time when the data standard set was created.

gmtModified

TimeStamp

1644459965000

The time when the data standard set was last modified.

creatorId

String

0123456

The ID of the user who creates the data standard set.

creatorName

String

A, B, C, and D

The name of the user who creates the data standard set.

modifierId

String

0123456

The ID of the user who last modifies the data standard set.

modifierName

String

A, B, C, and D

The name of the user who last modifies the data standard set.

FML statement used to query data standards

show dicts;

Response parameters

Parameter

Type

Example

Description

code

String

shop_type

The abbreviation for the name of the data standard.

englishName

String

shop type

The name of the data standard.

name

String

Shop type

The display name of the data standard.

no

String

SN00001

The data standard ID.

dataType

String

STRING

The data type of the fields that use the data standard.

length

Integer

10

The maximum number of digits in the values of the fields that use the data standard.

numericalPrecision

Integer

2

The number of decimal places that are retained in the values of the fields that use the data standard.

notNull

Boolean

false

Indicates whether the values of the fields that use the data standard can be non-null.

defaultValue

String

Flagship shop

The default value.

parentNo

String

SN0001

The ID of the parent data standard.

parentName

String

Shop

The name of the parent data standard.

codeTableNo

String

shop_type

The code of the lookup table that defines the value range of the fields that use the data standard.

codeTableName

String

Shop type

The name of the lookup table that defines the value range of the fields that use the data standard.

codeTableUuid

String

tb-0001

The UUID of the lookup table that defines the value range of the fields that use the data standard.

directoryUuid

String

Directory UUID

The UUID of the directory in which the data standard is stored.

directoryName

String

Shop directory

The name of the directory in which the data standard is stored.

description

String

remark

The description of the data standard.

uuid

String

obj-123456

The UUID of the data standard.

gmtCreate

TimeStamp

1644397025000

The time when the data standard was created.

gmtModified

TimeStamp

1644459965000

The time when the data standard was last modified.

creatorId

String

0123456

The ID of the user who creates the data standard.

creatorName

String

A, B, C, and D

The name of the user who creates the data standard.

modifierId

String

0123456

The ID of the user who last modifies the data standard.

modifierName

String

A, B, C, and D

The name of the user who last modifies the data standard.

FML statement used to query lookup tables

show code tables;

Response parameters

Parameter

Type

Example

Description

code

String

shop_type

The code of the lookup table.

name

String

Shop type

The display name of the lookup table.

extendName

String

shop type

The name of the lookup table.

description

String

remark

The description of the lookup table.

uuid

String

obj-123456

The UUID of the lookup table.

gmtCreate

TimeStamp

1644397025000

The time when the lookup table was created.

gmtModified

TimeStamp

1644459965000

The time when the lookup table was last modified.

creatorId

String

0123456

The ID of the user who creates the lookup table.

creatorName

String

A, B, C, and D

The name of the user who creates the lookup table.

modifierId

String

0123456

The ID of the user who last modifies the lookup table.

modifierName

String

A, B, C, and D

The name of the user who last modifies the lookup table.

FML statement used to query measurement unit groups

show measure_unit groups;

Response parameters

Parameter

Type

Example

Description

name

String

E-commerce

The name of the directory.

detailType

String

DICT

The type of the directory.

parentUuid

String

dy-123456

The UUID of the parent directory.

description

String

Description

The description of the directory.

code

String

ind

The code of the business category.

uuid

String

obj-123456

The UUID of the measurement unit group.

gmtCreate

TimeStamp

1644397025000

The time when the measurement unit group was created.

gmtModified

TimeStamp

1644459965000

The time when the measurement unit group was last modified.

creatorId

String

0123456

The ID of the user who creates the measurement unit group.

creatorName

String

A, B, C, and D

The name of the user who creates the measurement unit group.

modifierId

String

0123456

The ID of the user who last modifies the measurement unit group.

modifierName

String

A, B, C, and D

The name of the user who last modifies the measurement unit group.

FML statement used to query measurement units

show measure_units;

Response parameters

Parameter

Type

Example

Description

code

String

yuan

The abbreviation for the name of the measurement unit.

englishName

String

RMB

The name of the measurement unit.

name

String

Yuan

The display name of the measurement unit.

directoryUuid

String

di-0001

The UUID of the measurement unit group to which the measurement unit belongs.

directoryName

String

Currency

The name of the measurement unit group to which the measurement unit belongs.

description

String

remark

The description of the measurement unit.

uuid

String

obj-123456

The UUID of the measurement unit.

gmtCreate

TimeStamp

1644397025000

The time when the measurement unit was created.

gmtModified

TimeStamp

1644459965000

The time when the measurement unit was last modified.

creatorId

String

0123456

The ID of the user who creates the measurement unit.

creatorName

String

A, B, C, and D

The name of the user who creates the measurement unit.

modifierId

String

0123456

The ID of the user who last modifies the measurement unit.

modifierName

String

A, B, C, and D

The name of the user who last modifies the measurement unit.

FML statement used to query the data of a lookup table

show codes from code_table;

Response parameters

Parameter

Type

Example

Description

codeContent

String

0

The content of the lookup table.

extendNameContent

String

female

The display name of the lookup table.

nameContent

String

Female

The name of the lookup table.

description

String

remark

The description of the lookup table.

uuid

String

obj-123456

The UUID of the lookup table.

gmtCreate

TimeStamp

1644397025000

The time when the lookup table was created.

gmtModified

TimeStamp

1644459965000

The time when the lookup table was last modified.

creatorId

String

0123456

The ID of the user who creates the lookup table.

creatorName

String

A, B, C, and D

The name of the user who creates the lookup table.

modifierId

String

0123456

The ID of the user who last modifies the lookup table.

modifierName

String

A, B, C, and D

The name of the user who last modifies the lookup table.

FML statement used to query naming dictionaries

show naming dicts;

Response parameters

Parameter

Type

Example

Description

code

String

shop

The abbreviation for the name of the naming dictionary.

creatorId

String

0123456

The ID of the user who creates the naming dictionary.

creatorName

String

A, B, C, and D

The name of the user who creates the naming dictionary.

extendName

String

shop

The name of the naming dictionary.

gmtCreate

TimeStamp

1644397025000

The time when the naming dictionary was created.

gmtModified

TimeStamp

1644459965000

The time when the naming dictionary was last modified.

modifierId

String

0123456

The ID of the user who last modifies the naming dictionary.

modifierName

String

A, B, C, and D

The name of the user who last modifies the naming dictionary.

name

String

Shop

The display name of the naming dictionary.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

uuid

String

obj-123456

The UUID of the lookup table.

FML statement used to query tables

show tables;

Response parameters

Parameter

Type

Example

Description

code

String

dim_shop

The code of the table.

name

String

Shop table

The display name of the table.

type

Integer

1

The type of the table. Valid values: 0, 1, 3, 4, and 5.

0 indicates a fact table. 1 indicates a dimension table. 3 indicates an aggregate table. 4 indicates an application table. 5 indicates an ODS table.

detailType

String

normal

The subtype of the table. Valid values:

Common dimension table

Enumeration dimension table

Transaction fact table

businessProcessUuid

String

bp-123456

The UUID of the business process.

businessUnitUuid

String

bu-123456

The UUID of the business unit.

dataWarehouseLayerUuid

String

ly-123456

The UUID of the data layer.

businessCategoryUuid

String

bc-123456

The UUID of the business category.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

description

String

Description

The description of the table.

config

String

JSON string

The extended configurations for the table.

lifeCycle

Integer

365

The lifecycle of the table.

uuid

String

obj-123456

The UUID of the table.

gmtCreate

TimeStamp

1644397025000

The time when the table was created.

gmtModified

TimeStamp

1644459965000

The time when the table was last modified.

creatorId

String

0123456

The ID of the user who creates the table.

creatorName

String

A, B, C, and D

The name of the user who creates the table.

modifierId

String

0123456

The ID of the user who last modifies the table.

modifierName

String

A, B, C, and D

The name of the user who last modifies the table.

FML statement used to query dimension tables

show dim tables;

Response parameters

Parameter

Type

Example

Description

code

String

dim_shop

The code of the dimension table.

name

String

Shop table

The display name of the dimension table.

type

Integer

1

The type of the table. Valid values:

0: fact table

1: dimension table

detailType

String

normal

The subtype of the table. Valid values:

Common dimension table

Enumeration dimension table

businessProcessUuid

String

bp-123456

The UUID of the business process.

businessUnitUuid

String

bu-123456

The UUID of the business unit.

dataWarehouseLayerUuid

String

ly-123456

The UUID of the data layer.

businessCategoryUuid

String

bc-123456

The UUID of the business category.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

description

String

Description

The description of the dimension table.

config

String

JSON string

The extended configurations for the dimension table.

lifeCycle

Integer

365

The lifecycle of the dimension table.

uuid

String

obj-123456

The UUID of the dimension table.

gmtCreate

TimeStamp

1644397025000

The time when the dimension table was created.

gmtModified

TimeStamp

1644459965000

The time when the dimension table was last modified.

creatorId

String

0123456

The ID of the user who creates the dimension table.

creatorName

String

A, B, C, and D

The name of the user who creates the dimension table.

modifierId

String

0123456

The ID of the user who last modifies the dimension table.

modifierName

String

A, B, C, and D

The name of the user who last modifies the dimension table.

FML statement used to query fact tables

show fact tables;

Response parameters

Parameter

Type

Example

Description

code

String

dim_shop

The code of the fact table.

name

String

Shop table

The display name of the fact table.

type

Integer

1

The type of the table. Valid values:

0: fact table

1: dimension table

detailType

String

normal

The subtype of the table.

Only transaction fact tables are supported.

businessProcessUuid

String

bp-123456

The UUID of the business process.

businessUnitUuid

String

bu-123456

The UUID of the business unit.

dataWarehouseLayerUuid

String

ly-123456

The UUID of the data layer.

businessCategoryUuid

String

bc-123456

The UUID of the business category.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

description

String

Description

The description of the fact table.

config

String

JSON string

The extended configurations for the fact table.

lifeCycle

Integer

365

The lifecycle of the fact table.

uuid

String

obj-123456

The UUID of the fact table.

gmtCreate

TimeStamp

1644397025000

The time when the fact table was created.

gmtModified

TimeStamp

1644459965000

The time when the fact table was last modified.

creatorId

String

0123456

The ID of the user who creates the fact table.

creatorName

String

A, B, C, and D

The name of the user who creates the fact table.

modifierId

String

0123456

The ID of the user who last modifies the fact table.

modifierName

String

A, B, C, and D

The name of the user who last modifies the fact table.

FML statement used to query aggregate tables

show dws tables;

Response parameters

Parameter

Type

Example

Description

dataDomainUuid

String

dm-12345

The UUID of the data domain.

dataDomainCode

String

member

The code of the data domain.

dataDomainName

String

Member

The name of the data domain.

timePeriods

List

[{"uuid": "uuid", "code": "code", "name": "Display name"}]

The periods for the aggregate table.

uuid

String

obj-123456

The UUID of the aggregate table.

code

String

dws_001

The name of the aggregate table.

name

String

Payment aggregate table

The display name of the aggregate table.

adjuncts

List

[{"uuid": "uuid", "code": "code", "name": "Display name"}]

The modifiers for the aggregate table.

dimensions

List

[{"uuid": "uuid", "code": "code", "name": "Display name"}]

The dimensions that are associated with the aggregate table.

bizEntityUuid

String

dim-123456

The UUID of the business object.

bizEntityCode

String

dim_shop

The abbreviation for the name of the business object.

bizEntityName

String

Shop table

The display name of the business object.

relUuid

String

dim_a-123456

The UUID of the dimension that is associated with the aggregate table.

type

Integer

1

The type of the table. Valid values: 0, 1, and 3.

0 indicates a fact table. 1 indicates a dimension table. 3 indicates an aggregate table.

businessProcessUuid

String

bp-123456

The UUID of the business process.

businessUnitUuid

String

bu-123456

The UUID of the business unit.

dataWarehouseLayerUuid

String

ly-123456

The UUID of the data layer.

businessCategoryUuid

String

bc-123456

The UUID of the business category.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

description

String

Description

The description of the aggregate table.

config

String

JSON string

The extended configurations for the aggregate table.

lifeCycle

Integer

365

The lifecycle of the aggregate table.

gmtCreate

TimeStamp

1644397025000

The time when the aggregate table was created.

gmtModified

TimeStamp

1644459965000

The time when the aggregate table was last modified.

creatorId

String

0123456

The ID of the user who creates the aggregate table.

creatorName

String

A, B, C, and D

The name of the user who creates the aggregate table.

modifierId

String

0123456

The ID of the user who last modifies the aggregate table.

modifierName

String

A, B, C, and D

The name of the user who last modifies the aggregate table.

FML statement used to query application tables

show ads tables;

Response parameters

Parameter

Type

Example

Description

dataDomainUuid

String

dm-12345

The UUID of the data domain.

dataDomainCode

String

member

The code of the data domain.

dataDomainName

String

Member

The name of the data domain.

timePeriods

List

[{"uuid": "uuid", "code": "code", "name": "Display name"}]

The periods for the application table.

uuid

String

obj-123456

The UUID of the application table.

code

String

dws_001

The name of the application table.

name

String

Payment application table

The display name of the application table.

adjuncts

List

[{"uuid": "uuid", "code": "code", "name": "Display name"}]

The modifiers for the application table.

dimensions

List

[{"uuid": "uuid", "code": "code", "name": "Display name"}]

The dimensions that are associated with the application table.

bizEntityUuid

String

dim-123456

The UUID of the business object.

bizEntityCode

String

dim_shop

The abbreviation for the name of the business object.

bizEntityName

String

Shop table

The display name of the business object.

relUuid

String

dim_a-123456

The UUID of the dimension that is associated with the application table.

type

Integer

1

The type of the table. Valid values: 0, 1, and 4.

0 indicates a fact table. 1 indicates a dimension table. 4 indicates an application table.

businessProcessUuid

String

bp-123456

The UUID of the business process.

businessUnitUuid

String

bu-123456

The UUID of the business unit.

dataWarehouseLayerUuid

String

ly-123456

The UUID of the data layer.

businessCategoryUuid

String

bc-123456

The UUID of the business category.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

description

String

Description

The description of the application table.

config

String

JSON string

The extended configurations for the application table.

lifeCycle

Integer

365

The lifecycle of the application table.

gmtCreate

TimeStamp

1644397025000

The time when the application table was created.

gmtModified

TimeStamp

1644459965000

The time when the application table was last modified.

creatorId

String

0123456

The ID of the user who creates the application table.

creatorName

String

A, B, C, and D

The name of the user who creates the application table.

modifierId

String

0123456

The ID of the user who last modifies the application table.

modifierName

String

A, B, C, and D

The name of the user who last modifies the application table.

FML statement used to query tables and return the fields of each table

show full tables;

Response parameters

Parameter

Type

Example

Description

tableUuid

String

tb-123456

The UUID of the table.

tableCode

String

dim_shop

The code of the table.

tableName

String

Shop table

The name of the table.

columnCode

String

shop_id

The code of the column.

columnName

String

Shop ID

The name of the column.

columnUuid

String

col-123456

The UUID of the column.

columnType

String

STRING

The data type of the column.

columnCategory

String

ATTRIBUTE

The type of the column.

FML statement used to query information about the columns of a table

show columns from table_code;

Response parameters

Parameter

Type

Example

Description

code

String

seller_id

The code of the column.

name

String

Seller ID

The display name of the column.

dataType

String

STRING

The data type of the column.

type

String

ATTRIBUTE

The type of the field.

isPrimaryKey

Boolean

false

Indicates whether the field is a primary key column.

isPartitionKey

Boolean

false

Indicates whether the field is a partition key column.

partitionOrder

Integer

1

The order of the partition key column.

notNull

Boolean

true

Indicates whether the field is non-null.

dataDictionaryUuid

String

member_id

The UUID of the lookup table.

dataDictionaryCode

String

Member ID

The name of the lookup table.

codeTableUuid

String

cd-123456

The UUID of the lookup table.

codeTableCode

String

sex

The code of the lookup table.

codeTableName

String

Gender

The name of the lookup table.

measureUnitCode

String

percent

The code of the measurement unit.

measureUnitName

String

Fen

The name of the measurement unit.

sourceProjectName

String

autotest

The name of the source workspace.

sourceTableCode

String

dict

The code of the source table.

sourceColumnCode

String

age

The code of the source field.

sourceRelationTag

String

label

The tag of the source relationship.

description

String

Description

The description of the field.

orderId

String

1

The order of the field.

columnGroupName

Integer

col_group_1

The name of the group to which the field belongs.

config

String

JSON string

The extended configurations for the field.

uuid

String

obj-123456

The UUID of the field.

gmtCreate

TimeStamp

1644397025000

The time when the field was created.

gmtModified

TimeStamp

1644459965000

The time when the field was last modified.

creatorId

String

0123456

The ID of the user who creates the field.

creatorName

String

A, B, C, and D

The name of the user who creates the field.

modifierId

String

0123456

The ID of the user who last modifies the field.

modifierName

String

A, B, C, and D

The name of the user who last modifies the field.

FML statement used to query modifiers

show adjuncts;

Response parameters

Parameter

Type

Example

Description

businessUnitUuid

String

bu-123456

The UUID of the business unit.

businessUnitCode

String

test_bu

The code of the business unit.

businessUnitName

String

Test

The name of the business unit.

dataDomainUuid

String

dt-123456

The UUID of the data domain.

dataDomainCode

String

member

The code of the data domain.

dataDomainName

String

Member

The name of the data domain.

categoryUuid

String

cy-123456

The UUID of the business category.

categoryCode

String

trade

The code of the business category.

categoryName

String

E-commerce

The name of the business category.

type

AdjunctTypeEnum

DIM_VAL

The type of the modifier.

code

String

beauty

The abbreviation for the name of the modifier.

name

String

Makeup

The display name of the modifier.

extendName

String

beauty

The name of the modifier.

description

String

Description

The description of the modifier.

bizExpression

String

Statistical criterion

The statistical criterion of the modifier.

expression

String

beauty = 1

The expression of the modifier.

bizEntityUuid

String

dim-123456

The UUID of the business object.

bizEntityCode

String

dim_shop

The abbreviation for the name of the business object.

bizEntityName

String

Shop table

The display name of the business object.

relUuid

String

dim_a-123456

The UUID of the dimension that is associated with the modifier.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

isDeleted

DeleteTagEnum

NO

Indicates whether the modifier is deleted.

uuid

String

obj-123456

The UUID of the modifier.

gmtCreate

TimeStamp

1644397025000

The time when the modifier was created.

gmtModified

TimeStamp

1644459965000

The time when the modifier was last modified.

creatorId

String

0123456

The ID of the user who creates the modifier.

creatorName

String

A, B, C, and D

The name of the user who creates the modifier.

modifierId

String

0123456

The ID of the user who last modifies the modifier.

modifierName

String

A, B, C, and D

The name of the user who last modifies the modifier.

FML statement used to query periods

show time_periods;

Response parameters

Parameter

Type

Example

Description

businessUnitUuid

String

bu-123456

The UUID of the business unit to which the period belongs.

businessUnitCode

String

test_bu

The code of the business unit.

type

TimePeriodTypeEnum

DAY

The type of the period.

typeName

String

Day

The name of the type of the period.

code

String

1d

The abbreviation for the name of the period.

name

String

One day

The display name of the period.

extendName

String

1d

The name of the period.

description

String

Description

The description of the period.

isDeleted

DeleteTagEnum

NO

Indicates whether the period is deleted.

timeBegin

String

start_expression

The expression for the start time.

timeEnd

String

end_expression

The expression for the end time.

gmtCreate

TimeStamp

1633885261000

The time when the period was created.

gmtModified

TimeStamp

1633885261000

The time when the period was last modified.

modifierId

String

0123456

The ID of the user who last modifies the period.

modifierName

String

A, B, C, and D

The name of the user who last modifies the period.

ownerId

String

0123456

The owner ID.

ownerName

String

A, B, C, and D

The name of the owner.

beginOffset

Integer

1

The offset of the start time.

endOffset

Integer

1

The offset of the end time.

firstDay

Integer

1

The first day of the period. This parameter is returned if the type of the period is set to WEEK, MONTH, QUARTER, or YEAR. Valid values if the type of the period is set to WEEK: 1 to 7, which indicate Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, and Saturday. Valid values if the type of the period is set to MONTH: 1, 99, and 2 to 27. The value 1 indicates the first day of the month, The value 99 indicates the end of the month, and values from 2 to 27 indicate the 2nd to 27th days of the month. Valid values if the type of the period is set to QUARTER: 0 to 11, which indicate January to December. Valid values if the type of the period is set to YEAR: 0 to 11, which indicate January to December.

uuid

String

obj-123456

The UUID of the period.

creatorId

String

0123456

The ID of the user who creates the period.

creatorName

String

A, B, C, and D

The name of the user who creates the period.

FML statement used to query atomic metrics

show atomic indicators;

Response parameters

Parameter

Type

Example

Description

dataDistinct

YesOrNoEnum

YES

Indicates whether duplicate data is removed during statistics collection. Valid values:

YES

NO

aggFunctionType

AggFunctionEnum

SUM

The type of the function for the atomic metric. Valid values:

SUM

COUNT

AVG

MAX

MIN

RATE

RANK

UNDEFINED

calExpression

String

price

The expression of the atomic metric.

dataType

DataTypeNameEnum

TINYINT

The type of data that can be collected by the atomic metric. Valid values: TINYINT, SMALLINT, INT, BIGINT, BINARY, FLOAT, DOUBLE, DECIMAL, VARCHAR, CHAR, STRING, DATE, DATETIME, TIMESTAMP, BOOLEAN, ARRAY, MAP, STRUCT, and JSON

dataRound

String

N

The number of decimal places after the decimal point. Valid values:

N

M

dataUnitUuid

String

du-123456

The UUID of the metric unit.

dataUnitCode

String

percent

The code of the metric unit.

dataUnitName

String

Fen

The name of the metric unit.

bizExpression

String

Aggregation of payment amount

The statistical criterion of the atomic metric.

dataRollUpType

String

AGG_FUNCTION

The method of the data roll-up. Valid values:

AGG_FUNCTION

SUM_THEN_RATE

RATE_THEN_AVG

NOT_SUPPORT

businessUnitUuid

String

bu-0001

The UUID of the business unit.

businessUnitCode

String

project_code

The code of the business unit.

businessProcessUuid

String

di-0002

The UUID of the business process.

businessProcessCode

String

pay

The code of the business process.

businessProcessName

String

Payment

The name of the business process.

dataDomainUuid

String

di-0003

The UUID of the data domain.

dataDomainCode

String

trd

The code of the data domain.

dataDomainName

String

Transaction

The name of the data domain.

categoryUuid

String

di-0001

The UUID of the business category.

categoryCode

String

tb

The code of the business category.

categoryName

String

Taobao

The name of the business category.

type

String

ATOMIC

The type of the metric. Valid values:

ATOMIC

DERIVATIVE

DERIVATIVE_COMPOSITE

code

String

pay_amt

The abbreviation for the name of the atomic metric.

name

String

Payment amount

The display name of the atomic metric.

extendName

String

pay amount

The name of the atomic metric.

description

String

remark

The description of the atomic metric.

status

String

NORMAL

The status of the atomic metric. Valid values:

DRAFT

DEV

NORMAL

ownerId

String

0001

The owner ID.

ownerName

String

Owner name

The name of the owner.

isDeleted

DeleteTagEnum

NO

Indicates whether the atomic metric is deleted. Valid values:

YES

NO

uuid

String

obj-123456

The UUID of the atomic metric.

gmtCreate

TimeStamp

1644397025000

The time when the atomic metric was created.

gmtModified

TimeStamp

1644459965000

The time when the atomic metric was last modified.

creatorId

String

0123456

The ID of the user who creates the atomic metric.

creatorName

String

A, B, C, and D

The name of the user who creates the atomic metric.

modifierId

String

0123456

The ID of the user who last modifies the atomic metric.

modifierName

String

A, B, C, and D

The name of the user who last modifies the atomic metric.

FML statement used to query derived metrics

show derivative indicators;

Response parameters

Parameter

Type

Example

Description

timePeriodUuid

String

tp-0001

The UUID of the period.

timePeriodCode

String

1d

The abbreviation for the name of the period.

timePeriodName

String

Last day

The display name of the period.

adjunctUuids

List

["adj-001"]

The UUIDs of modifiers.

adjunctCodes

List

["male"]

The abbreviations for the names of modifiers.

adjunctNames

List

Male

The display names of modifiers.

atomicIndicatorUuid

String

ind-a-0001

The UUID of the atomic metric.

atomicIndicatorCode

String

pay_amt

The abbreviation for the name of the atomic metric.

atomicIndicatorName

String

Payment amount

The display name of the atomic metric.

dataType

DataTypeNameEnum

BIGINT

The type of data that can be collected by the derived metric. Valid values: TINYINT, SMALLINT, INT, BIGINT, BINARY, FLOAT, DOUBLE, DECIMAL, VARCHAR, CHAR, STRING, DATE, DATETIME, TIMESTAMP, BOOLEAN, ARRAY, MAP, STRUCT, and JSON

bizEntityUuid

String

dim-123456

The UUID of the business object.

bizEntityCode

String

dim_shop

The abbreviation for the name of the business object.

bizEntityName

String

Shop table

The display name of the business object.

relUuid

String

dim_a-123456

The UUID of the dimension that is associated with the derived metric.

indHash

String

hash-0001

The hash value for the elements of the derived metric.

suggestCode

String

pay_amt_1d

The recommended code that is used by the derived metric.

businessUnitUuid

String

bu-0001

The UUID of the business unit.

businessUnitCode

String

project_code

The code of the business unit.

businessProcessUuid

String

di-0002

The UUID of the business process.

businessProcessCode

String

pay

The code of the business process.

businessProcessName

String

Payment

The name of the business process.

dataDomainUuid

String

di-0003

The UUID of the data domain.

dataDomainCode

String

trd

The code of the data domain.

dataDomainName

String

Transaction

The name of the data domain.

categoryUuid

String

di-0001

The UUID of the business category.

categoryCode

String

tb

The code of the business category.

categoryName

String

Taobao

The name of the business category.

type

IndicatorTypeEnum

ATOMIC

The type of the metric. Valid values:

ATOMIC

DERIVATIVE

DERIVATIVE_COMPOSITE

code

String

pay_amt

The abbreviation for the name of the derived metric.

name

String

Payment amount

The display name of the derived metric.

extendName

String

pay amount

The name of the derived metric.

description

String

remark

The description of the derived metric.

status

IndicatorStatusEnum

NORMAL

The status of the derived metric. Valid values:

DRAFT

DEV

NORMAL

ownerId

String

0001

The owner ID.

ownerName

String

Owner name

The name of the owner.

isDeleted

DeleteTagEnum

NO

Indicates whether the derived metric is deleted. Valid values:

YES

NO

uuid

String

obj-123456

The UUID of the derived metric.

gmtCreate

TimeStamp

1644397025000

The time when the derived metric was created.

gmtModified

TimeStamp

1644459965000

The time when the derived metric was last modified.

creatorId

String

0123456

The ID of the user who creates the derived metric.

creatorName

String

A, B, C, and D

The name of the user who creates the derived metric.

modifierId

String

0123456

The ID of the user who last modifies the derived metric.

modifierName

String

A, B, C, and D

The name of the user who last modifies the derived metric.

FML statement used to query composite metrics

show derivative composite indicators;

Response parameters

Parameter

Type

Example

Description

businessUnitCode

String

project_code

The name of the workspace.

businessProcessUuid

String

di-0002

The UUID of the business process.

businessProcessCode

String

pay

The code of the business process.

businessProcessName

String

Payment

The name of the business process.

dataDomainUuid

String

di-0003

The UUID of the data domain.

dataDomainCode

String

trd

The code of the data domain.

dataDomainName

String

Transaction

The name of the data domain.

categoryUuid

String

di-0001

The UUID of the business category.

categoryCode

String

tb

The code of the business category.

categoryName

String

Taobao

The name of the business category.

type

String

DERIVATIVE_COMPOSITE

The computing logic. Valid values: DERIVATIVE_COMPOSITE and DERIVATIVE_COMPARISON. DERIVATIVE_COMPOSITE indicates a calculation expression. DERIVATIVE_COMPARISON indicates comparison.

code

String

pay_amt

The abbreviation for the name of the composite metric.

name

String

Payment amount

The display name of the composite metric.

extendName

String

pay amount

The name of the composite metric.

description

String

remark

The description of the composite metric.

calculateExpression

String

{@pay_amt_1d[Last day_Payment amount]}/{@pay_amt_1m[Last 30 days_Payment amount]}

The calculation expression.

comparisonPeriodType

String

DAY_MOM

The comparison type. Valid values: DAY_MOM, WEEK_MOM, WEEK_YOY, MONTH_MOM, MONTH_YOY, QUARTER_MOM, YEAR_MOM, and YEAR_YOY.

comparisonIndicatorUuid

String

obj-123456

The UUID of the composite metric that is used for comparison.

comparisonIndicatorCode

String

pay_amt_1d

The abbreviation for the name of the composite metric that is used for comparison.

comparisonIndicatorName

String

Last day_Payment amount

The display name of the composite metric that is used for comparison.

ownerId

String

0001

The ID of the owner of the composite metric.

ownerName

String

Bob

The name of the owner of the composite metric.

isDeleted

DeleteTagEnum

NO

Indicates whether the composite metric is deleted. Valid values: YES and NO.

uuid

String

obj-123456

The UUID of the composite metric.

gmtCreate

TimeStamp

1644397025000

The time when the composite metric was created.

gmtModified

TimeStamp

1644459965000

The time when the composite metric was last modified.

creatorId

String

0123456

The ID of the user who creates the composite metric.

creatorName

String

A, B, C, and D

The name of the user who creates the composite metric.

modifierId

String

0123456

The ID of the user who last modifies the composite metric.

modifierName

String

A, B, C, and D

The name of the user who last modifies the composite metric.

FML statement used to query information about the model on which a single metric depends

show statistic indicator table_code;

Response parameters

Parameter

Type

Example

Description

uuid

String

obj-123456

The UUID of the metric.

code

String

pay_amt

The abbreviation for the name of the metric.

name

String

Payment amount

The display name of the metric.

extendName

String

pay amount

The name of the metric.

relations

List<EntityInfo>

Example

The information about the model on which the metric depends. You can view the following code and table to obtain the structure of the EntityInfo parameter.

Sample structure and description of the EntityInfo parameter

[
    {
        "uuid": "uuid",
        "code": "code",
        "name": "The display name",
        "extendName": "full name in English",
        "entityType": "EntityTypeEnum.BASE_DERIVATIVE_INDICATOR",
        "entityTypeName": "The type name of the entity",
        "entitySubType": "DERIVATIVE_INDICATOR",
        "entitySubTypeName": "The subtype name of the entity",
        "ownerId": "0001",
        "ownerName": "The name of the owner"
    }
]

Parameter

Type

Example

Description

uuid

String

obj-123456

The UUID of the model.

code

String

dws_001

The abbreviation for the name of the model.

name

String

Payment aggregate table

The display name of the model.

extendName

String

dws_001

The name of the model.

entityType

EntityTypeEnum

Table

The entity type of the metric. The values of this parameter include but are not limited to

TABLE, BASE_ATOMIC_INDICATOR, and BASE_DERIVATIVE_INDICATOR.

entityTypeName

String

Table

The type name of the entity.

entitySubType

String

DWS_TABLE

The subtype of the entity. The values of this parameter include but are not limited to

DWS_TABLE, ATOMIC_INDICATOR, and DERIVATIVE_INDICATOR.

entitySubTypeName

String

Aggregate table

The subtype name of the entity.

ownerId

String

0001

The owner ID.

ownerName

String

Alice

The name of the owner.

Examples

Sample requests

http(s)://[Endpoint]/?Action=QueryPublicModelEngine
&Text=show dim tables
&ProjectId=1234
&<Common request parameters>

Description of sample requests

The following code is the sample demo of the SDK for Java:   
 QueryPublicModelEngineRequest request = new QueryPublicModelEngineRequest();            
 request.setProjectId(this.projectId);    
 request.setText("show layers;");    
 QueryPublicModelEngineResponse response = client.getAcsResponse(request);    
 // The following sample code provides an example on how to return data in the JSON format. Process the returned data based on your business requirements when you use the sample code.    
 ObjectMapper objectMapper = new ObjectMapper();    
 objectMapper.enable(SerializationFeature.INDENT_OUTPUT);    
 objectMapper.setTimeZone(TimeZone.getTimeZone("GMT+8"));    
 String s = objectMapper.writeValueAsString(obj);    
 System.out.println(s);    

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<QueryPublicModelEngineResponse>
    <RequestId>4CFB2DED-7D9B-4C42-B4AA-CFF4991DFFF4</RequestId>
    <ReturnValue/>
</QueryPublicModelEngineResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "4CFB2DED-7D9B-4C42-B4AA-CFF4991DFFF4",
  "ReturnValue" : [ null ]
}

Additional description of sample responses

The following results are returned for the sample demo of the SDK for Java:   
 {
  "requestId" : "x-request-id",  
  "returnValue" : [ {  
    "uuid" : "obj-123456",  
    "gmtCreate" : 1638857552348,  
    "gmtModified" : 1638857552351,  
    "creatorId" : "0123456",  
    "creatorName" : "A, B, C, and D",  
    "modifierId" : "0123456",  
    "modifierName" : "A, B, C, and D",  
    "code" : "dws",  
    "englishName" : "dws",  
    "name" : "DWS layer",  
    "ownerId" : "0123456",  
    "ownerName" : "A, B, C, and D",  
    "description" : "Description of the DWS layer"  
  } ]  
}

Error codes

HTTP status code

Error code

Error message

Description

400

Valid.FML.NoPermission

You are not authorized to access the project resources.

You are not granted the required permissions to access the resources in the current workspace.

400

Valid.FML.OnlySupportQueryStatement

Only FML query statement is supported.

Only FML statements are supported.

400

Valid.FML.ProjectNotExist

The project does not exist.

Information about the workspace is not found. Check input parameters.

400

Valid.FML.StatementNotValid

The FML statement is invalid.

The FML statement is invalid. For more information, see the FML syntax documentation at https://dataworks-doc.yuque.com/docs/share/ff7899ed-c433-4970-b20e-6582ea3939f3?#.

400

Valid.FML.ProductExpired

The Data Modeling service that you activate is expired.

The Data Modeling service that you activate is expired.

400

Valid.FML.ProductNotActivated

The Data Modeling service is not activated.

The Data Modeling service is not activated.

500

Execute.FML.ProcessError

Failed to execute FML statement.

The FML statement fails to be executed. Try again later.

For a list of error codes, see Service error codes.