WhereIsEmpty: TriState;
The WhereIsEmpty property determines whether factors, for which emptiness indicator is set, can be exported.
Available values:
TriState.OnOption. Empty factors are exported.
TriState.OffOption. Only non-empty factors are exported.
TriState.Undefined. Default value. All factors are exported.
The IRubricator.HasEmptyAttribute property determines whether the database includes an indicator of time series emptiness.
Executing the example requires a time series database with the FC_IS_EMPTY identifier. This database must contain the COUNTRY custom attribute. Add links to the Metabase, Cubes, Dt, Dal system assemblies.
Sub UserProc;
Var
TextConsumer: IDtTextConsumer;
MB: IMetabase;
Exporter: ICubeMetaExporter;
Binding: ICubeMetaExporterBinding;
Begin
// Data successor to export to the textual format
TextConsumer := New DtTextConsumer.Create;
TextConsumer.File := "C:\result_meta_exp.txt";
TextConsumer.FormatType := DtTextFormatType.Delimited;
TextConsumer.DelimitedColumnDelimiter := ";";
TextConsumer.DelimitedTextQualifier := """";
TextConsumer.Encoding := "WIN";
TextConsumer.WriteHeader := True;
// Export parameters of the COUNTRY attribute
Exporter := New CubeMetaExporterClass.Create;
MB := MetabaseClass.Active;
Exporter.Rubricator := MB.ItemById("FC_IS_EMPTY").Bind As IRubricator;
Exporter.Consumer := TextConsumer As IDtConsumer;
Binding := Exporter.Bindings.Add;
Binding.FieldName := "COUNTRY_KEY";
Binding.DataType := DbDataType.Integer;
Binding.BindingType := CubeMetaExporterBindingType.Attribute;
Binding.Attribute := "COUNTRY";
Binding.KeyField := "KEY";
// Calendar parameters of export
Binding := Exporter.Bindings.Add;
Binding.FieldName := "Year";
Binding.DataType := DbDataType.String;
Binding.BindingType := CubeMetaExporterBindingType.Calendar;
Binding.DateFormat := "$Year$";
// Data export parameters
Binding.ValueFieldName := "Value";
Binding.ValueDataType := DbDataType.Float;
Exporter.WhereIsEmpty := TriState.OffOption;
// Export
Exporter.Export;
End Sub UserProc;
After executing the example non-empty database series are loaded to the C:\result_meta_exp.txt file.
See also: