The datamart and bulk export properties for a report that is configured as a datamart or bulk export report are saved to 'DatamartProperties' and 'BulkExportProperties' property sets respectively. However, the property sets belong to the 'Datamart' report which is an embedded object within the report definition.
The following code explains how users can set these property set values through the Strategy Intelligence Server SDK 10.0.x API:
After obtaining a report object, the code should iterate through the Embedded objects in the report and check if the type of embedded object is a datamart.
Dim thisDMDefinition As IDSSDatamart
With thisRepDefn.Info.Embedded
For iEmbedded = 1 To .Count
If (.Item(iEmbedded).Type = DssTypeDatamart) Then
Set thisDMDefinition = .Item(iEmbedded)
End If
Next iEmbedded
End With
The property sets for DatamartProperties and BulkExportProperties are saved for the embedded datamart report. The following example shows how users can access the 'DatamartProperties' property set:
Dim oPropertySet As IDSSPropertySet
With thisDMDefinition.Info.PropertySets
For iSet = 1 To .Count
Set oPropertySet = .Item(iSet)
If (StrComp(oPropertySet.Info.Name, "DatamartProperties") = 0) Then
' code to modify the DatamartProperties property set ...
End If
Next iSet
End With
After setting the required property set, users must save the report definition to be able to save the changes. For example to set the Table Type to 'Temporary Table' for the datamart:
Dim oProperty As IDSSProperty
Set oProperty = oPropertySet.Item(14)
If (StrComp(oProperty.Name, "Table Type") = 0) Then
oProperty.Value = 1
thisRepDefn.Info.Save
End If
CUSTOMIZATION WARNING
This customization is provided as a convenience to Strategy users and is only directly applicable to the version stated. While this code may apply to other releases directly, Strategy Technical Support makes no guarantees that the code provided will apply to any future or previous builds. In the event of a code change in future builds, Strategy Technical Support makes no guarantee that an updated version of this particular customization will be provided. In the event of a code change in future builds, Strategy may not be able to provide additional code on this matter even though this customization is provided at this time for this specific build. For enhancements to this customization or to incorporate similar functionality into other versions, contact your Account Executive to inquire about Strategy consulting assistance.
Type the body of the How-To technical note in step-by-step format two lines beneath the ABSTRACT. Be sure to include numbered steps to help the reader follow the information you are providing.