You can call this operation to enumerate all the databases, tables, and columns of a cluster.

Debugging

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

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeAllDataSource

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

DBClusterId String Yes am-bp1xxxxxxxx47

The ID of the cluster.

SchemaName String Yes adb_demo

The name of the database.

TableName String Yes test

The name of the table.

Response parameters

Parameter Type Example Description
Columns Array of Column

The list of columns.

Column
AutoIncrementColumn Boolean true

Specifies whether the columns are auto-incremented.

ColumnName String id

The name of the column.

DBClusterId String am-bp1xxxxxxxx47

The ID of the cluster.

PrimaryKey Boolean false

Indicates whether the column is a primary key.

SchemaName String adb_demo

The name of the database.

TableName String test

The name of the table.

Type String bigint

The data type of the column.

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

The ID of the request.

Schemas Array of Schema

The list of databases.

Schema
DBClusterId String am-bp1xxxxxxxx47

The ID of the cluster.

SchemaName String adb_demo

The name of the database.

Tables Array of Table

The list of tables.

Table
DBClusterId String am-bp1xxxxxxxx47

The ID of the cluster.

SchemaName String adb_demo

The name of the database.

TableName String test

The name of the table.

Examples

Sample requests

http(s)://[Endpoint]/? Action=DescribeAllDataSource
&DBClusterId=am-bp1xxxxxxxx47
&SchemaName=adb_demo
&TableName=test
&<Common request parameters>

Sample success responses

XML format

<RequestId>1AD222E9-E606-4A42-BF6D-8A4442913CEF</RequestId>
<Tables>
    <Table>
        <TableName>adb_oss_import_test</TableName>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>adb_demo</SchemaName>
    </Table>
    <Table>
        <TableName>customer</TableName>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>adb_demo</SchemaName>
    </Table>
    <Table>
        <TableName>test</TableName>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>adb_demo</SchemaName>
    </Table>
</Tables>
<Columns>
    <Column>
        <TableName>test</TableName>
        <ColumnName>id</ColumnName>
        <Type>bigint</Type>
        <AutoIncrementColumn>true</AutoIncrementColumn>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <PrimaryKey>false</PrimaryKey>
        <SchemaName>adb_demo</SchemaName>
    </Column>
    <Column>
        <TableName>test</TableName>
        <ColumnName>name</ColumnName>
        <Type>varchar</Type>
        <AutoIncrementColumn>false</AutoIncrementColumn>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <PrimaryKey>false</PrimaryKey>
        <SchemaName>adb_demo</SchemaName>
    </Column>
    <Column>
        <TableName>test</TableName>
        <ColumnName>value</ColumnName>
        <Type>int</Type>
        <AutoIncrementColumn>false</AutoIncrementColumn>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <PrimaryKey>false</PrimaryKey>
        <SchemaName>adb_demo</SchemaName>
    </Column>
    <Column>
        <TableName>test</TableName>
        <ColumnName>ts</ColumnName>
        <Type>timestamp</Type>
        <AutoIncrementColumn>false</AutoIncrementColumn>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <PrimaryKey>false</PrimaryKey>
        <SchemaName>adb_demo</SchemaName>
    </Column>
</Columns>
<Schemas>
    <Schema>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>test_adb</SchemaName>
    </Schema>
    <Schema>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>a123</SchemaName>
    </Schema>
    <Schema>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>test</SchemaName>
    </Schema>
    <Schema>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>adb_demo</SchemaName>
    </Schema>
    <Schema>
        <DBClusterId>am-bp1xxxxxxxx47</DBClusterId>
        <SchemaName>test_db</SchemaName>
    </Schema>
</Schemas>

JSON format

{
    "RequestId": "1AD222E9-E606-4A42-BF6D-8A4442913CEF",
    "Tables": {
        "Table": [
            {
                "TableName": "adb_oss_import_test",
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "adb_demo"
            },
            {
                "TableName": "customer",
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "adb_demo"
            },
            {
                "TableName": "test",
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "adb_demo"
            }
        ]
    },
    "Columns": {
        "Column": [
            {
                "TableName": "test",
                "ColumnName": "id",
                "Type": "bigint",
                "AutoIncrementColumn": true,
                "DBClusterId": "am-bp1xxxxxxxx47",
                "PrimaryKey": false,
                "SchemaName": "adb_demo"
            },
            {
                "TableName": "test",
                "ColumnName": "name",
                "Type": "varchar",
                "AutoIncrementColumn": false,
                "DBClusterId": "am-bp1xxxxxxxx47",
                "PrimaryKey": false,
                "SchemaName": "adb_demo"
            },
            {
                "TableName": "test",
                "ColumnName": "value",
                "Type": "int",
                "AutoIncrementColumn": false,
                "DBClusterId": "am-bp1xxxxxxxx47",
                "PrimaryKey": false,
                "SchemaName": "adb_demo"
            },
            {
                "TableName": "test",
                "ColumnName": "ts",
                "Type": "timestamp",
                "AutoIncrementColumn": false,
                "DBClusterId": "am-bp1xxxxxxxx47",
                "PrimaryKey": false,
                "SchemaName": "adb_demo"
            }
        ]
    },
    "Schemas": {
        "Schema": [
            {
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "test_adb"
            },
            {
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "a123"
            },
            {
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "test"
            },
            {
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "adb_demo"
            },
            {
                "DBClusterId": "am-bp1xxxxxxxx47",
                "SchemaName": "test_db"
            }
        ]
    }
}

Error codes

HttpCode Error code Error message Description
404 InvalidDBCluster.NotFound The DBClusterId provided does not exist in our records. The error message returned because the specified DBClusterId parameter does not exist. Check whether you specify the DBClusterId parameter correctly.

For a list of error codes, visit the API Error Center.