1. A method of performing a query on spatial data in a database comprising: receiving the query on the spatial data in the database, the database comprising at least one partitioned data table where each data table partition in the at least one partitioned data table includes spatial data representing a contiguous spatial region and at least one partitioned spatial index where each spatial index partition is for a data table partition in the at least one partitioned data table and includes index data to the data table partition and index metadata defining the data table partition and the spatial index partition; obtaining index metadata from a distinct column of the respective spatial index partition for each data table partition wherein the index metadata for the spatial data in each data table partition comprises a minimum bounding rectangle for spatial data in the respective data table partition; determining, for each data table partition, whether the data table partition is relevant to the query, using the index metadata for the data table partition by determining whether the minimum bounding rectangle for spatial data in the data table partition intersects with a minimum bounding rectangle for the query; processing the query on each relevant data table partition; and retrieving spatial data from a relevant data table partition based on an intersection between the spatial data and the query.