Background information
In ODC V4.3.2 and later, you can run time-consuming SQL statements in logical database change tasks to change data in the logical database without causing statement execution timeout.
Note
- If you do not have the required privileges on the logical database, you can apply for the required logical database privileges by clicking Apply for database privileges in the project or ticket.
- For more information about logical databases and physical databases, see Manage logical databases.
Considerations
Only MySQL and OceanBase MySQL compatible mode data sources are supported.
Only DDL changes are supported.
SQL check specifications and SQL window specifications included in the ODC security specifications are not supported.
Create a logical database change task
Choose Projects > All Projects. On the tab that appears, click the project name.
On the Tickets tab, choose Logical Database Change > Create New.
On the Create Logical Database Change page, configure the following parameters and click Create.
ParameterDescriptionLogical Database The logical database to be changed. SQL Content The method for writing SQL statements. Valid values: SQL Entry and SQL File. The SQL entry method is the default method. Delimiter The delimiter. Task Settings Specify whether to Execute Immediately or Execute On Schedule. Timeout The timeout period in hours for statement execution. Specify the timeout period in the Execution Timeout field. The default timeout period is 48 hours, with a maximum of 480 hours. Description The description of the task. You can enter up to 200 characters in the Ticket Description field. This parameter is optional. After the task is created, you can go to Tickets > Logical Database Change to view the task information.
View the logical database change task
Go to Tickets > Logical Database Change, and click the name of the target task in the task list to view the task details. You can also click the ··· in the Actions column to perform more operations on the task.
- Execute: When the task is set to manual execution, you can manually execute the task.
- Terminate: When the task is set to periodic or scheduled execution, you can terminate the task.
- Disable/Enable: When the task is set to periodic or scheduled execution, you can disable the task to temporarily stop its execution. The task will resume execution after it is enabled.
- Edit: When the task is disabled, you can edit the task content.
- Delete: When the task is completed or terminated, you can delete the task.
- View: View the task content.
- Clone: Copy the task execution content to quickly generate a new task with the same configuration.
- Share: Quickly copy the task's access address.
In the task details panel that appears, the Basic Information tab is displayed by default. You can view the task type, database, variable configuration, and execution method.
Note
You can configure whether to allow query and download of query results in the system settings. For more information, see System settings.
Click the Workflow tab to view the task initiation status, approval status, execution status, and execution result.
Click the Execution Records tab to view the execution success and failure records.
Click the Logs tab to view all logs and alert logs of the task.
ItemDescriptionAll Logs All logs display the INFO, ERROR, and WARN logs of the task. You can click the Find, Download, and Copy buttons to find, download, or copy all logs. Alert Logs Alert logs display the ERROR and WARN logs of the task. When the task fails, you can view the error information in the alert logs. You can click the Find, Download, and Copy buttons to find, download, or copy alert logs.
