[MDEV-8349] Multi table join indexes Created: 2015-06-22 Updated: 2015-07-16 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | Data Definition - Alter Table |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major |
| Reporter: | Norbert van Nobelen | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 1 |
| Labels: | None | ||
| Description |
|
At this moment virtually all databases can only use single table indexing (except Oracle (composite indexes) and SQL Server (indexes on views)). A multi table join index however is a very efficient index for use in many applications with almost static query paths. They virtually eliminate the need for materialized views or jobs creating "temporary" tables which are refreshed on a regular basis. The workings: The Join is described in the create index statement: Proposed syntax: ON TABLE_A.COL=TABLE_B.COL The index is limited in the optimizer to work only in the condition when the exact criteria for the index are met. For example: The index is updated (real time) when an insert/update/delete operation occurs in one of the underlying tables. Since the impact of this update can be larger then the update of an index on a single table, the following requirement for performance of the index comes in view: The multi table join index has to contain partially empty nodes: |