Check an export target table name

Checks the database in the OmniFabric connector to see if a table with the specified name already exists. This operation does not create or modify the target table.

HTTP
POST $CLOUDSIGMA_API_BASE/connectors/mo/check_table_name

Before you call

Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region.

  1. Prepare personal access token and target workspace ID that can access the target workspace.

  2. Get the OmniFabric connector ID from Query Connector List.

Requires the export task creation permission of the target workspace and the use permission of the target connector.

Request body

Replace the connector, database, and table names in $CLOUDSIGMA_API_KEY, $WORKSPACE_ID, and examples with actual values.

Shell
curl -X POST "$CLOUDSIGMA_API_BASE/connectors/mo/check_table_name" \
  -H "X-API-Key: $CLOUDSIGMA_API_KEY" \
  -H "X-Workspace-ID: $WORKSPACE_ID" \
  -H "Content-Type: application/json" \
  -d @- <<EOF
{
    "connector_id": "$CONNECTOR_ID",
    "database": "analytics",
    "table": "orders"
  }
EOF

Parameter

Type

Required

Description

connector_id

string

Yes

OmniFabric target connector ID.

database

string

Yes

The name of the target database to check.

table

string

Yes

The name of the target table to check.

Successful response

JSON
{
  "code": "OK",
  "msg": "OK",
  "data": {
    "exists": false
  }
}

Field

Type

Description

code

string

OK on success.

msg

string

OK on success.

data.exists

boolean

true indicates that there is already a table with the same name. false indicates that the table with the same name was not found.

Error response

JSON
{
  "code": "ErrServer",
  "msg": "无法读取目标数据库"
}

Field

Type

Description

code

string

error code.

msg

string

Readable error message.

Last updated on