Use the INSERT INTO statement to populate local cubes with dimension structure and data. If the cube file specified in the DBPROP_INIT_DATASOURCE property does not exist, it will be created during processing of the INSERT INTO statement.
The INSERT INTO statement is used after a CREATE CUBE statement. These statements are used together to create a local cube.
The INSERT INTO statement can perform the following operations on a local cube:
The INSERT INTO statement maps columns of the local cube’s data source to elements (levels and measures) in the cube.
The dimension structure of a local cube can be populated during the execution of the INSERT INTO statement by using a SELECT clause executed on the data source. This clause generates the cube’s dimension trees and measures. After the SELECT clause has been executed, the dimensions of the cube are fully populated and become static.
Note You can use methods other than the SELECT clause to populate the dimension structure of a local cube.
Data can be read from the data source into the local cube in one of two modes:
The entire tables are read from the data source when the local cube is created. The data is persisted in the local cube file, and the data source is then disconnected. This method of population produces a local MOLAP (multidimensional OLAP) cube.
Data is sent to the client computer only when necessary to fulfill a request such as a query from the client application. The cube definition, including the dimension structure, is persisted in the local cube file, but the source table data is not. This method of population is used by local ROLAP (relational OLAP) cubes.
The OPTIONS DEFER_DATA clause is used in the INSERT INTO statement to specify deferred data population. For more information, including information about the related ATTEMPT_DEFER_DATA option, see INSERT INTO.