Creating a Table

Operation Description

A data table consists of basic information, columns, and indexes. As the supplement to table information, indexes are optional and can be configured based on service requirements.

Procedure

  1. On the top menu bar, choose Database Management. On the displayed Objects page, select Tables and click Create Table.
  2. On the displayed page, specify required parameters and set advanced options as required. The table name is mandatory. Click Next.
  3. Set the column name, type, length, nullable, primary key, and extended information based on service requirements.

    • If you do not need to add indexes, click Create directly. In the displayed SQL Preview dialog box, click Execute.
    • GaussDB(for MySQL) data management tables are classified into global tables, unsharded tables, and sharded tables. If you select Yes for Global Table, the table created is a global one. If you select No for Global Table, an unsharded table will be created.
    • To create sharded tables, execute SQL statements in the SQL window.
    • If you need to add indexes, click Next and set the index information. After the setting is complete, click Create at the bottom of the page.

  4. In the SQL Preview dialog box, click Execute to create a table.