Retrieving Metadata from an Analytical Data Source
Metadata is important to applications that retrieve and work with analytical data. When retrieving data from a relational data source, the dimensionality of such data is predictable, even with nested datasets. Result sets from a relational database are typically two-dimensional or scalar in structure. However, data retrieved from analytical data sources can be of variable dimensionality, organized along potentially deep hierarchies.
To handle the complexity of metadata retrieval from analytical data sources, ADOMD.NET provides two forms of metadata retrieval:
The Object Model
The ADOMD.NET object model is generally easier to use than schema rowsets. For most scenarios, you can access the metadata of various database objects just by using the object model. ADOMD.NET exposes the object model through the AdomdConnection.For more information: Working with the ADOMD.NET Object Model
Schema Rowsets
A complete, but more difficult approach to retrieving metadata is through using schema rowsets. A schema rowset is an OLE DB rowset that encapsulates the description for all objects of a particular type in the database. Schema information in an analytical data source includes databases or catalogs available from the data source, cubes and mining models in a database, roles that exist for cubes at the data source, and so on. This metadata can be retrieved by using the GetSchemaDataSet method, passing in either a GUID or an XML for Analysis (XMLA) name.For more information: Working with Schema Rowsets in ADOMD.NET
Each of these metadata retrieval methods access different types of metadata. The following table describes the different metadata available for each method, and the methods used to access it.
GUID (used in Schema Rowsets) |
XMLA Name (used in Schema Rowsets) |
ADOMD.NET Object Model |
---|---|---|
DISCOVER_CONNECTIONS |
||
AdomdConnection.Cubes |
||
DISCOVER_DB_CONNECTIONS |
||
AdomdConnection.Cubes[].Dimensions |
||
DISCOVER_DIMENSION_STAT |
||
AdomdConnection.Cubes[].Dimensions[].Hierarchies |
||
DISCOVER_JOBS |
||
AdomdConnection.Cubes[].KPIs |
||
AdomdConnection.Cubes[].Dimensions[].Hierarchies[].Levels |
||
DISCOVER_LOCATIONS |
||
DISCOVER_LOCKS |
||
DISCOVER_MASTER_KEY |
||
AdomdConnection.Cubes[].Measures |
||
PropertyCollection available from most major ADOMD.NET objects. |
||
AdomdConnection.Cubes[].Dimensions[].Hierarchies[].Levels[].GetMembers() |
||
DISCOVER_MEMORYGRANT |
||
DISCOVER_MEMORYUSAGE |
||
AdomdConnection.MiningModels[].MiningModelColumns |
||
AdomdConnection.MiningModels[].MiningContentNodes |
||
AdomdConnection.MiningModels |
||
AdomdConnection.MiningServices[].MiningServiceParameters |
||
AdomdConnection.MiningServices |
||
AdomdConnection.MiningStructures[].MiningStructureColumns |
||
AdomdConnection.MiningStructures |
||
DISCOVER_PARTITION_DIMENSION_STAT |
||
DISCOVER_PARTITION_STAT |
||
DISCOVER_PERFORMANCE_COUNTERS |
||
DISCOVER_SESSIONS |
||
AdomdConnection.Cubes[].NamedSets |
||
DBSCHEMA_TABLES_INFO |
||
DISCOVER_TRACE_COLUMNS |
||
DISCOVER_TRACE_DEFINITION_PROVIDERINFO |
||
DISCOVER_TRACE_EVENT_CATEGORIES |
||
DISCOVER_TRACES |
||
DISCOVER_TRANSACTIONS |
||