Previous Page | Next Page

Overview of Querying Metadata

Using GetMetadata to Get a Repository's Regular Attributes

To get general information about a repository, such as its Engine=, MetadataCreated=, and MetadataUpdated= values, use the GetMetadata method and set the OMI_ALL (1) flag.

The following GetMetadata method call, which is formatted for the INMETADATA parameter of the DoRequest method, requests information about the Foundation repository:

<GetMetadata>
   <Metadata>
         <RepositoryBase  Id="A0000001.A55WR3E8" Name="Foundation" />
   </Metadata>
  <NS>REPOS</NS>
  <Flags>1</Flags>
   <Options/>
</GetMetadata>

In the method call, note the following:

Here is an example of the output returned from the request:

<!-- Using the GETMETADATA method. -->

<GetMetadata>
   <Metadata>
         <RepositoryBase  Id="A0000001.A55WR3E8" Name="Foundation" Access="0" 
Desc=" " Engine="BASE" MetadataCreated="09Apr2008:18:06:57" MetadataUpdated=
"18Sep2008:18:47:54" Options=" " Path="C:\SAS\FoundationServers\Lev1\SASMain\
MetadataServer\MetadataRepositories\Foundation" 
RepositoryFormat="11" RepositoryType="FOUNDATION">
         <DependencyUsedBy/>
           <DependencyUses/>
      </RepositoryBase>
   </Metadata>
  <NS>REPOS</NS>
  <Flags>1</Flags>
   <Options/>
</GetMetadata>

The GetMetadata method returns the following attribute values that are not returned by the GetRepositories method: Engine=, MetadataCreated=, MetadataUpdated=, and Options=. The value Access="0" is comparable to OMS_FULL and means ONLINE with full access.

A GetMetadataObjects method that is issued in the REPOS namespace on the RepositoryBase metadata type with the OMI_GET_METADATA (256) flag and OMI_ALL (1) flag set will get this same information for all registered repositories.

Previous Page | Next Page | Top of Page