Deleting a Database

Function

This API is used to delete an empty database. If there are tables in the database to be deleted, delete all tables first. For details about the API used to delete tables, see Deleting a Table.

URI

Request

None

Response

Table 3 Response parameters

Parameter

Mandatory

Type

Description

is_success

No

Boolean

Whether the request is successfully executed. Value true indicates that the request is successfully executed.

message

No

String

System prompt. If execution succeeds, the parameter setting may be left blank.

job_id

No

String

Returned job ID, which can be used to obtain the job status and result.

job_type

No

String

Type of a job. The options are as follows:

  • DDL
  • DCL
  • IMPORT
  • EXPORT
  • QUERY
  • INSERT

job_mode

No

String

Job execution mode. The options are as follows:

  • async: asynchronous
  • sync: synchronous

Example Request

None

Example Response

Status Codes

Table 4 describes the status code.

Table 4 Status codes

Status Code

Description

200

Deletion succeeded.

400

Request error.

500

Internal service error.

Error Codes

If an error occurs when this API is invoked, the system does not return the result similar to the preceding example, but returns the error code and error information. For details, see Error Codes.