Patent ID: 8131713

Claim:
A method for managing information on a multi-tenant database system, the method comprising: storing the information on the database among a plurality of tables, the plurality of tables being arranged in columns and rows; for each of a subset of the plurality of tables, distributing sets of the rows amongst different tenant storage areas in the database according to either a physical arrangement or a logical arrangement, with a first of the sets being located at a first tenant storage area and a second of the sets being located at a second tenant storage area; and keeping tenant-level statistics on a per-tenant basis in the first and second tenant storage areas; and providing data storage and retrieval capabilities to the multi-tenant database system in response to requests from one of a plurality of remotely disposed computer systems, wherein the data storage and retrieval capabilities include at least: a) consulting the tenant-level statistics, and b) programmatically generating syntax of a query based on the tenant-level statistics.