> For the complete documentation index, see [llms.txt](https://learn.capstorm.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://learn.capstorm.com/copystorm-restore/best-practices/create-copystorm-indexes.md).

# Create Copystorm Indexes

CopyStorm/Restore will perform parent/child record analysis much faster if the CopyStorm database foreign keys are fully indexed.

To create the necessary indexes, check the [“Create Indexes” checkbox](https://learn.capstorm.com/copystorm/readme/reference/configuration-tab/database-indexing) on CopyStorm’s Configuration tab and rerun CopyStorm.

![](/files/RB0jqH3ohlNtt1qbJUCR)

## What Happens if Indexes Are Not Created?

CopyStorm/Restore will still work without indexes but the analysis required to determine the order in which records must be restored will be much slower. For databases with millions of rows the performance is likely to be unbearable. This is because CopyStorm/Restore needs to do a lot of table scans by running queries like:

* `SELECT id FROM Contact WHERE accountId IN (….)`

These will cause the entire Contact table to be scanned (an Order(n) operation). After creating the indexes, each lookup is an Order(1) operation (e.g. 1000s of times faster).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://learn.capstorm.com/copystorm-restore/best-practices/create-copystorm-indexes.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
