index-best-practices.html 848 B

12345678910111213141516
  1. Before creating an index, consider the following:
  2. - If you create stacked views (i.e., views that depend on other views) to
  3. reduce SQL complexity, we recommend that you create an index **only** on the
  4. view that will serve results, taking into account the expected data access
  5. patterns.
  6. - Materialize can reuse indexes across queries that concurrently access the same
  7. data in memory, which reduces redundancy and resource utilization per query.
  8. In particular, this means that joins do **not** need to store data in memory
  9. multiple times.
  10. - For queries that have no supporting indexes, Materialize uses the same
  11. mechanics used by indexes to optimize computations. However, since this
  12. underlying work is discarded after each query run, take into account the
  13. expected data access patterns to determine if you need to index or not.