When Omnidex indexing is added to an Omnidex Environment, only the metadata about each index is added to the environment. The indexes themselves are not populated until an UPDATE INDEXES statement is issued. This is of great benefit since it allows multiple indexes to be built with one scan of the table. Omnidex applications frequently use many Omnidex indexes, and building them individually would be prohibitively slow. The example below updates all of the indexes for a table.
> update indexes for table HOUSEHOLDS Database Table Rows CPU Elapsed ---------------------------------------------------------------------------- SIMPLE HOUSEHOLDS 1,909 0:00 0:00 ---------------------------------------------------------------------------- Total 0:00 0:00 Omnidex indexes updated >
Most commonly, administrators update the indexes for all tables in the environment with one command, as shown below.
> update indexes Database Table Rows CPU Elapsed ---------------------------------------------------------------------------- SIMPLE HOUSEHOLDS 1,909 0:00 0:00 INDIVIDUALS 5,000 0:00 0:00 ---------------------------------------------------------------------------- Total 0:00 0:03 Omnidex indexes updated >
If needed, an individual index can be populated without affecting the other indexes, so long as the index was created with the STANDALONE option.
> update indexes for index HOUSEHOLDS.STATE_CITY_ZIP; Database Table Rows CPU Elapsed ---------------------------------------------------------------------------- SIMPLE HOUSEHOLDS 1,909 0:00 0:03 ---------------------------------------------------------------------------- Total 0:00 0:04 Index (HOUSEHOLDS)HOUSEHOLDS.STATE_CITY_ZIP updated >
See also: