Extract

Extracts metadata into a text file. The file will be created on the application server.

Tip:

You can extract files onto client PCs with the HsvMetadataLoadACV type library. This library also offers properties and methods that simplify handling of the metadata extract options. For more information, see Extracting Metadata .

Syntax

<HsvMetadata>.Extract bstrServerFilename, bstrServerLogFilename, varavSettings

Argument

Description

bstrServerFilename

String (ByVal). The name and path of the metadata extract file. The path must exist on the application server.

bstrServerLogFilename

String (ByVal). The name and path of the log file. The path must exist on the application server.

varavSettings

Variant array (ByVal). The metadata extract options. The array is 1-based and contains 19 items. For details on valid indexes and values, see Table 57, Metadata Extract Options.

Tip:

Use EnumExtractOptions to return information about the valid extract options.

The following table describes the metadata extract options. Note that the listed indexes apply to the array passed to Extract and to the first dimension of the array returned by EnumExtractOptions.

Table 57. Metadata Extract Options

Index

Extract Option Information

1

Option: Currencies

Usage: Specifies whether currencies are extracted.

Pass to Extract: Boolean — TRUE to extract currencies, otherwise FALSE.

2

Option: Scenarios

Usage: Specifies whether scenarios are extracted.

Pass to Extract: Boolean — TRUE to extract scenarios, otherwise FALSE.

3

Option: Years

For internal use.

4

Option: Periods

For internal use.

5

Option: Views

For internal use.

6

Option: Entities

Usage: Specifies whether entities are extracted.

Pass to Extract: Boolean — TRUE to extract entities, otherwise FALSE.

7

Option: Accounts

Usage: Specifies whether accounts are extracted.

Pass to Extract: Boolean — TRUE to extract accounts, otherwise FALSE.

8

Option: Custom1

Usage: Specifies whether Custom 1 dimension members are extracted.

Pass to Extract: Boolean — TRUE to extract Custom 1 members, otherwise FALSE.

9

Option: Custom2

Usage: Specifies whether Custom 2 dimension members are extracted.

Pass to Extract: Boolean — TRUE to extract Custom 2 members, otherwise FALSE.

10

Option: Custom3

Usage: Specifies whether Custom 3 dimension members are extracted.

Pass to Extract: Boolean — TRUE to extract Custom 3 members, otherwise FALSE.

11

Option: Custom4

Usage: Specifies whether Custom 4 dimension members are extracted.

Pass to Extract: Boolean — TRUE to extract Custom 4 members, otherwise FALSE.

12

Option: Delimiter

Usage: Specifies an extract file’s delimiter.

Pass to Extract: String — a valid delimiter character. EnumExtractOptions returns the valid delimiters.

13

Option: AppSettings

Usage: Specifies whether application settings are extracted.

Pass to Extract: Boolean — TRUE to extract application settings, otherwise FALSE.

14

Option: FileFormat

Usage: Specifies whether the metadata extract file is in an ASCII text or an XML format.

Pass to Extract: Long — 0 to extract into a text file, 1 to extract into an XML file.

15

Option: ConsolMethods

Usage: Specifies whether consolidation methods are extracted.

Pass to Extract: Boolean — TRUE to extract consolidation methods, otherwise FALSE.

16

Option: ExtractSystemMembers

Usage: Specifies whether system members are extracted.

Pass to Extract: Boolean — TRUE to extract system members, otherwise FALSE.

Note:

If this option is set to TRUE, you must also set to TRUE the options for the system members to be extracted.

17

Option: SystemAccounts

Usage: Specifies whether system-generated Account dimension members are extracted.

Pass to Extract: Boolean — TRUE to extract system accounts, otherwise FALSE. If this option is set to TRUE you must also set the ExtractSystemMembers option to TRUE.

18

Option: Values

Usage: Specifies whether Value dimension members are extracted.

Pass to Extract: Boolean — TRUE to extract Value dimension members, otherwise FALSE. These are system members, so if this option is set to TRUE you must also set the ExtractSystemMembers option to TRUE.

19

Option: ICPs

Usage: Specifies whether Intercompany Partner dimension members are extracted.

Pass to Extract: Boolean — TRUE to extract Intercompany Partner dimension members, otherwise FALSE. These are system members, so if this option is set to TRUE you must also set the ExtractSystemMembers option to TRUE.

Example

The following example extracts metadata into an XML file. The custom function getMetadataExtractDefaults assigns the default extract options to the vaSettings array; for the definition of this custom function, see the example for EnumExtractOptions. The file format option — item 14 of the vaSettings array — is set to XML, then Extract is called.

Dim vaOpts As Variant, vaSettings() As Variant
vaSettings = getMetadataExtractDefaults()
vaSettings(14) = 1
'g_cMetadata is an HsvMetadata object reference
g_cMetadata.Extract "c:\acme\myAppExt.xml", _
  "c:\acme\myappExt.log", vaSettings