MDX Documentation

OLAP Schema Factories

Schema/cube factories are the internal data structures used by icCube to describe schemas and cubes. Actually, the icCube builder UI defines such structures. So, most users should not need to manually edit those factories. Nevertheless, advanced users might prefer to manually edit them and/or might need to tweak some definitions not available yet in the UI.

icCube allows you to create OLAP schemas and cubes directly from one or more files (e.g. CSV) or from Excel sheets. Those files, or Excel sheets, contain both the actual cube dimensions and facts data as well as some sort of meta-information describing the dimension structures (more on this in following chapters).

Once those data files/sheets are created, cube factories are used to register them within the icCube server. Those factories are simple XML wrappers actually creating a cube definition linked to the files (a.k.a. datasource).

To get a quick idea of what such a factory looks like, here is the factory file salesExcelFactory.icc-schema used in the working example 'Sales (Excel)' cube:

<cubeBasedSchemaFactory
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:noNamespaceSchemaLocation="http://www.crazy-development.com/schemas/icSchemaFactory.xsd">

    <schemaName>Sales (Excel)</schemaName>
    <schemaDescription>A schema example defining a single cube built from Excel sheets.</schemaDescription>
    <schemaGroup>Examples</schemaGroup>

    <cubeFactories>

        <excelCubeFactory>

            <cubeName>Sales</cubeName>
            <excelFileName>data/sales.xls</excelFileName>

        </excelCubeFactory>

    </cubeFactories>

</cubeBasedSchemaFactory>
    

This factory is defining a single cube called 'Sales (Excel)' built from the Excel sheets contained in the file data/sales.xls.

Registering a cube (or its factory file) into the icCube server is done using the Web monitoring console as shown in the following image. Note the location of the icCube schema/cube directory. Factory files must be placed within that directory. icCube is shipped with several working examples located within that directory.

To be recognized by the icCube builder, the name of the factory files must have the extension .icc-schema (case sensitive):

Factory Monitoring

Note: icCube is not limited to the type of cube factories shipped with each version. In fact, thanks to the plug-ins framework, you may add new cube factories. Thus, allowing you to access your own data the way you like. See the plugins chapter for more details.

Next chapter: Cube Factory: Single File shows how to create a cube using a single file in more detail.