40.1. Creating an Index #

  1. In the navigation panel, go to Databases.

  2. (Optional) To display system databases, turn on Show system databases.

  3. Click the name of the database.

  4. Click the name of the schema.

  5. Click the name of the table.

  6. In the top-right corner of the page, click Create index.

  7. Specify parameters of the new index (parameters marked with an asterisk are required):

    • Name.

    • Concurrently building: Specifies whether the index will be created in a special mode that minimizes the number of locks and reduces the risk of their occurrence when there are concurrent workloads.

    • Unique index: Specifies whether to control duplicate table values when creating the index and adding new values to it.

    • Columns: Columns that will be included in the index.

      To add a column:

      1. Click Add column +.

      2. Specify parameters of the new column (parameters marked with an asterisk are required):

        • Column: The name of the column.

        • Operator class: The operators that will be used by the index for the column.

        • Collation: The collation for the column.

        • Order: The sorting order for the column.

          Possible values:

          • Default

          • Ascending

          • Descending

        • NULL's order: The sorting order of the NULL values.

          Possible values:

          • Default

          • NULL first

          • NULL last

      The Operator class, Collation, Order, and NULL's order parameters are available only if you turn on Extended settings.

  8. (Optional) In the top-right corner of the window, turn on Extended settings and specify additional parameters:

    • Tablespace: The tablespace where the index will be located.

    • Using method: The access method.

      Possible values:

      • btree

      • gin

      • gist

      • brin

      • hash

    • Where predicate: The condition of the index.

    • lock_timeout, s: Abort any statement that waits longer than the specified time while attempting to acquire a lock on a table, index, row, or other database object. The time limit applies separately to each lock acquisition attempt.

      For more information about this parameter, refer to the official Postgres Pro documentation.

  9. Click Create.