IRubricatorDictionaryLookup.LookupFactorsC

Syntax

LookupFactorsC: Array;

Description

The LookupFactors method returns the composite keys array of the found time series.

Comments

The IRubricatorDictionaryLookup.WhereCompoundFactorKey property determines the composite key of the time series.

Example

Executing the example requires that the repository contains a time series database with the RUBRICATOR_CUBE identifier. Add links to the Metabase, Cubes system assemblies.

Sub UserProc;
Var
    mb: IMetabase;
    RubI: IRubricatorInstance;
    pFactsLookup: IRubricatorFactsLookup;
    CompKey: Array[2];
    Key, arr: Array Of Variant;
    i, idx: Integer;
    s: String;
Begin
    mb := MetabaseClass.Active;
    RubI := mb.ItemById("RUBRICATOR_CUBE").Open(NullAs IRubricatorInstance;
    pFactsLookup := RubI.CreateFactsLookup;
    CompKey[0] := 512; CompKey[1] := 1009;
    pFactsLookup.WhereCompoundFactorKey := CompKey;
    If pFactsLookup.LookupFactorsC <> Null Then
        i := pFactsLookup.LookupFactorsC.Length;
    Debug.WriteLine(Found: + i.ToString);
        Key := New Variant[i];
        Key := pFactsLookup.LookupFactorsC;
        For i := 0 To Key.Length - 1 Do
            arr := Key[i] As Array Of Variant;
            s := "";
            For idx := 0 To arr.Length - 1 Do
                s := s + (arr[idx] As string) + "; ";
            End For;
            Debug.WriteLine(s);
        End For;
    End If;
End Sub UserProc;

Example execution result: the search by the values of a composite key is executed in the time series database, and results are displayed in the console window.

See also:

IRubricatorDictionaryLookup