GetViewObjects

Updated at:
Copy as MD

Queries view information.

Operation description

  • The public endpoint for the region: adb.<region-id>.aliyuncs.com. Example: adb.cn-hangzhou.aliyuncs.com.

  • The VPC endpoint for the region: adb-vpc.<region-id>.aliyuncs.com. Example: adb-vpc.cn-hangzhou.aliyuncs.com.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

DBClusterId

string

Yes

The cluster ID.

am-bp1xxxxxxxx47

SchemaName

string

No

The database name.

adb_demo

OrderBy

string

No

The sort field. Valid values for Type:

  • Asc

  • Desc

Valid values for Field:

  • ViewName

  • CreateTime

  • UpdateTime

Default value: {"Type": "Desc","Field": "ViewName"}.

{"Type": "Desc","Field": "ViewName"}

FilterViewName

string

No

The view name.

test_filter

PageNumber

integer

No

The page number.

1

PageSize

integer

No

The number of entries per page. Valid values:

  • 30 (default)

  • 50

  • 100

30

FilterViewType

string

No

The view type.

Valid values:

  • VIRTUAL_VIEW

  • MATERIALIZED_VIEW

Default value: null.

VIRTUAL_VIEW

FilterOwner

string

No

The owner.

admin

RegionId

string

Yes

The region ID.

cn-hangzhou

ShowMvBaseTable

boolean

No

Specifies whether to display the base table information of the materialized view.

true

Response elements

Element

Type

Description

Example

object

The response result.

RequestId

string

The request ID.

1AD222E9-E606-4A42-BF6D-8A4442913CEF

PageNumber

integer

The page number. The value must be a positive integer that is greater than 0 and does not exceed the maximum value of the Integer data type. Default value: 1.

1

PageSize

integer

The number of entries per page. Valid values:

  • 30 (default)

  • 50

  • 100

30

TotalCount

integer

The total number of entries.

1

Data

object

The response struct.

PageNumber

integer

The page number. The value must be a positive integer that is greater than 0 and does not exceed the maximum value of the Integer data type. Default value: 1.

1

PageSize

integer

The number of entries per page. Valid values:

  • 30 (default)

  • 50

  • 100

30

TotalCount

integer

The total number of entries.

1

TableSummaryModels

array

The result array.

TableSummaryModel

The view summary information.

Examples

Success response

JSON format

{
  "RequestId": "1AD222E9-E606-4A42-BF6D-8A4442913CEF",
  "PageNumber": 1,
  "PageSize": 30,
  "TotalCount": 1,
  "Data": {
    "PageNumber": 1,
    "PageSize": 30,
    "TotalCount": 1,
    "TableSummaryModels": [
      {
        "SchemaName": "schemaName",
        "TableName": "tableName",
        "TableType": "PHYSICAL_SCHEMA_NAME",
        "TableSize": 1234,
        "CreateTime": "2023-01-05 13:17:55",
        "UpdateTime": "2023-01-05 13:17:55",
        "SQL": "create table(a varchar)",
        "Description": "descrtiption",
        "Owner": "abc",
        "MvDetailModel": {
          "FirstRefreshTime": "2025-01-01 09:00:00",
          "QueryRewriteEnabled": false,
          "ExplicitHit": 5,
          "IsInactive": false,
          "RemoteSize": 1234,
          "LocalSize": 1234,
          "RefreshState": "FAST",
          "RefreshInterval": "(now() + INTERVAL '10' SECOND)",
          "ImplicitHit": 20,
          "UpdatedAt": "2025-01-01 10:00:00",
          "ResourceGroup": "user_default",
          "BaseTableInfos": [
            {
              "SchemaName": "test_db",
              "TableName": "test_tbl",
              "BaseTableIsMv": false,
              "TableEngine": "XUANWU"
            }
          ],
          "TableEngine": "XUANWU",
          "BaseTableNames": [
            [
              "t1"
            ]
          ],
          "EnableDelayAlert": 0,
          "EnableFailureAlert": 0,
          "LatencyTolerance": 2
        },
        "CreatedBySource": "XIHE",
        "CreatedByUser": "example_user"
      }
    ]
  }
}

Error codes

HTTP status code

Error code

Error message

Description

400 MDS.IllegalArgument Invalid argument. An invalid parameter is used.
400 MDS.InvalidPrivilege No permissions. You are not authorized to perform this operation.
400 MDS.MetaSchemaAlreadyExist The database already exists. The specified database already exists.
400 MDS.MetaSchemaNotExist The database does not exist. The specified database does not exist.
400 MDS.MetaTableAlreadyExist The table already exists. The specified table already exists.
400 MDS.MetaTableNotExist The table is not found. The specified table does not exist.
500 MDS.InternalError An internal MDS error occurred. An internal error occurred.
500 MDS.MetaVisitError Failed to access metadata. Failed to access the metadata.
403 MDS.RamAuthAccessDenied ram auth access denied. RAM authentication failed

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.