Data Management (DMS) provides the Cmd Tab feature for you to write and execute SQL statements in the form of commands. The executed SQL statements and execution results are displayed in the upper part of the Cmd Tab tab. This topic describes the GUI of this tab.

Prerequisites

  • The database to be queried is a relational database, such as a MySQL, an Oracle, or an SQL Server database.
  • You have permissions to query the database or table that you want to query. For more information about how to apply for permissions, see Permission management.

Procedure

  1. Log on to the DMS console V5.0.
    Note To switch to the previous version of the DMS console, click the 5租户头像 icon in the lower-right corner of the page. For more information, see Switch to the previous version of the DMS console.
  2. In the top navigation bar, click SQL Console. The SQL Console tab appears.
    Note If you are using the previous version of the DMS console, move the pointer over the More icon in the top navigation bar and choose SQLConsole > Single Database Query.
  3. In the Please select the database first dialog box, enter a keyword to search for a database, select the database from the search results, and then click Confirm.
  4. On the Table tab, move the pointer over the table that you want to query, right-click the table, and then select Cmd Tab.
  5. In the editor in the lower part of the Cmd Tab tab, enter the SQL statement that you want to execute and click Execute or press Ctrl+Enter.