DataImportService.setCubeImportProps

Syntax

setCubeImportProps (cubeImport, sourceType, props, fields, unpivot, fieldsFromSource, callback, errorCallback)

Parameters

CubeImport. Model of object import to cube. instance of the PP.Mb.CubeImport class.

sourceType. Type of data source, an instance of the PP.Mb.SourceType enumeration.

props. Data source parameters.

fields. Data source fields.

unpivot. Mode of report start point use.

fieldsFromSource. Use of source fields.

callback. Callback function.

errorCallback. Callback function on error.

Description

The setCubeImportProps method sets import object parameters.

Example

To execute the example, the page must contain ImportDataWizard component named importDataWizard and a service for working with data import named dataImportService (see Example of Creating the ImportDataWizard Component), it is required to select an import object and go to the second wizard page. Set import object parameters again:

// Get settings of the second wizard page
flatT = importDataWizard.getSteps()[1];
// Get required settings
cube = flatT.getCubeImport();
type = flatT.getSourceType();
set = flatT.getSourceSettings();
fields = flatT.getStepSettings().Fields;
unPivot = flatT.getUnpivot();
// Determine data source settings
dataImportService.setCubeImportProps(cube, type, set, fields, unPivot, false);

After executing the example data source settings are reapplied.

See also:

DataImportService