For the complete documentation index, see llms.txt. This page is also available as Markdown.

Indexes

Add database indexes to improve query performance on your custom tables.

Database indexes speed up queries by allowing MySQL to find rows without scanning the entire table. You configure indexes in Step 3 of the table wizard.

When to add an index

Add an index on a column if you:

  • Filter or search records by that column frequently

  • Use that column in a WHERE clause in REST API queries

  • Join tables on that column via a foreign key (MySQL often does this automatically for foreign keys)

Indexes improve read performance at the cost of slightly slower writes. For small tables (< 1,000 rows) the difference is negligible.

Creating an index

  1. Open the table wizard and navigate to Step 3 — Indexes.

  2. Click Add index.

  3. Fill in the index settings:

Field
Description

Index name

Unique identifier for this index within the table.

Key parts

The columns included in the index. Multi-column (composite) indexes are supported.

Index type

See types below.

Indexes step of the table wizard
Step 3 — Indexes, with an index configured on director_id.

Index types

Type
Description

INDEX

Standard B-tree index. Suitable for most query patterns.

UNIQUE

Enforces uniqueness across the indexed column(s). Use for columns that must not contain duplicate values.

FULLTEXT

Optimized for full-text search on text and longtext columns. Enables MATCH ... AGAINST queries.

SPATIAL

Used for geometric/geographic data types. Rarely needed for standard CCT use cases.

Example

For a movies table that is frequently filtered by year and director_id:

Index name
Key parts
Type

idx_year

year

INDEX

idx_director

director_id

INDEX

Deleting an index

Click the Delete icon next to the index in Step 3 of the wizard. The index is removed from the database the next time the table schema is synced.

Last updated