ebook img

SAS Warehouse Administrator 2.3 Metadata API Reference, 2nd edition PDF

309 Pages·2004·2.24 MB·English
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview SAS Warehouse Administrator 2.3 Metadata API Reference, 2nd edition

SAS/Warehouse Administrator® 2.3 Metadata API Reference Second Edition The correctbibliographic citationfor thismanual isasfollows: SASInstituteInc. 2004. SAS/WarehouseAdministrator®2.3MetadataAPIReference, Second Edition. Cary,NC:SASInstituteInc. SAS/Warehouse Administrator®2.3Metadata APIReference, Second Edition Copyright ©2004, SASInstituteInc., Cary,NC, USA ISBN 1-59047-222-5 Allrightsreserved. Produced intheUnitedStates ofAmerica. Nopart ofthispublication maybe reproduced, storedina retrievalsystem, or transmitted,inanyform orby any means, electronic,mechanical,photocopying, orotherwise,without thepriorwritten permissionofthepublisher, SASInstituteInc. U.S. GovernmentRestrictedRights Notice. Use,duplication, ordisclosure ofthis softwareandrelated documentation bytheU.S. governmentissubjectto theAgreement with SASInstituteandtherestrictionssetforthinFAR 52.227–19Commercial Computer Software-Restricted Rights (June1987). SASInstitute Inc.,SASCampusDrive,Cary,North Carolina27513. 1stprinting, January2004 SASPublishing provides acompleteselection ofbooksandelectronicproducts tohelp customers useSASsoftwaretoits fullestpotential. Formore informationaboutour e-books,e-learningproducts,CDs,andhard-copybooks,visittheSASPublishingWebsite at support.sas.com/pubsorcall 1-800-727-3228. SAS®andallotherSASInstituteInc. productorservicenamesareregisteredtrademarks or trademarksofSASInstituteInc. in theUSA andother countries. ® indicatesUSA registration. Other brandandproductnames areregisteredtrademarksor trademarksoftheir respective companies. Contents Chapter 1 Introduction to the Metadata API 1 Changes and Enhancements 1 Prerequisites 4 What is Metadata? 4 What is the SAS/Warehouse Administrator Metadata API? 5 What Can I Do with the SAS/Warehouse Administrator Metadata API? 5 How the Metadata API Works 5 Identifying Metadata 7 Reading Metadata: A Simple Example 8 Metadata Repositories 10 Learning to Use the Metadata API 12 Naming Conventions Used in This Manual 12 Where Metadata API Classes and SLISTS are Stored 12 Chapter 2 Metadata API Class 13 Overview of the Metadata API Class 13 Using the Metadata API Class 14 Introduction to Metadata API Methods 14 Index to Metadata API Methods 16 Chapter 3 SAS/Warehouse Administrator Metadata Types 51 Overview of SAS/Warehouse Administrator Metadata Types 51 Metadata Type Inheritance 52 Using Metadata Types 53 Index to SAS/Warehouse Administrator Metadata Types 70 Using the Metadata Type Dictionary 73 Appendix 1 Sample Metadata API Code 273 Appendix Overview 273 Read Metadata Code Sample 273 Write Metadata Code Sample 277 Appendix 2 Metadata Type Inheritance Tree 281 SAS/Warehouse Administrator Metadata Type Inheritance Tree 281 Appendix 3 Recommended Reading 285 Recommended Reading 285 Glossary 287 Index 295 iv 1 C H A P T E R 1 Introduction to the Metadata API ChangesandEnhancements 1 Prerequisites 4 WhatisMetadata? 4 WhatistheSAS/WarehouseAdministratorMetadataAPI? 5 WhatCanIDowiththeSAS/WarehouseAdministratorMetadataAPI? 5 HowtheMetadataAPIWorks 5 IdentifyingMetadata 7 ReadingMetadata: ASimpleExample 8 MetadataRepositories 10 SettingtheActiveMetadataRepository 11 LearningtoUsetheMetadataAPI 12 NamingConventionsUsedinThisManual 12 WhereMetadataAPIClassesandSLISTSareStored 12 Changes and Enhancements This section describes changes to the SAS/Warehouse Administrator metadata API after Release 2.0. (cid:0) You can add and update the PATH property for the WHEFILE type. (cid:0) You can now use the metadata API to add, update, and delete process objects. For example, you can write a metadata API program that creates a data store and also creates all of the processes that are required to extract, transform, and load information into that data store. The following metadata types have been updated to support this feature: (cid:0) WHCOLUMN (cid:0) WHCOLDTL (cid:0) WHCOLDAT (cid:0) WHCOLODD (cid:0) WHCOLOLP (cid:0) WHCOLTIM (cid:0) WHCTRNFM (cid:0) WHEFILE (cid:0) WHEXTATR (cid:0) WHINDEX (cid:0) WHOLAP (cid:0) WOLPDIM 2 ChangesandEnhancements Chapter1 (cid:0) WOLPHIR (cid:0) WOLPCRS (cid:0) WOLPCUB (cid:0) WHPHYSTR (cid:0) WHDMSST (cid:0) WHSASSTR (cid:0) WHPOBJECT (cid:0) WHJOB (cid:0) WHGRPJOB (cid:0) WHEVENT (cid:0) WHTFILE (cid:0) WHTXTFIL (cid:0) WHSCRFIL (cid:0) WHTXTCAT (cid:0) WHNOTE (cid:0) WHSRCCAT (cid:0) WHJOBCAT (cid:0) WHDW (cid:0) WHDWENV (cid:0) WHINFO (cid:0) WHINFOFL (cid:0) WHTABLE (cid:0) WHDATTBL (cid:0) WHDETAIL (cid:0) WHLDETL (cid:0) WHODDTBL (cid:0) WHODTTBL (cid:0) WHSUMTBL (cid:0) WHOLPSTC (cid:0) WHGRPOLP (cid:0) WHOLPTBL (cid:0) WHOLPMDD (cid:0) WHTBLPRC (cid:0) WHTBLMAP (cid:0) WHTBLREC (cid:0) WHTBLUSR (cid:0) WHTBLXFR (cid:0) WHPROCES (cid:0) WHPRCMAN (cid:0) WHPRCMAP (cid:0) WHPRCREC (cid:0) WHPRCUSR IntroductiontotheMetadataAPI ChangesandEnhancements 3 (cid:0) WHPRCXFR (cid:0) WHPRCLDR (cid:0) WHLDRDAT (cid:0) WHLDRDTL (cid:0) WHLDREXT (cid:0) WHLDRINF (cid:0) WHLDRIMF (cid:0) WHLDRLDT (cid:0) WHLDRMDB (cid:0) WHLDRODD (cid:0) WHLDRODT (cid:0) WHLDRSUM (cid:0) WHLDOTBL (cid:0) WHLDOMDD (cid:0) WHLDOPRX (cid:0) WHPRCSPR (cid:0) WHPRCPST (cid:0) WHSUBSET (cid:0) WHROWSEL (cid:0) The TABLE OPTIONS property of the WHDBMSST type has a new sublist—the APPEND sublist. The APPEND sublist contains any SAS/ACCESS LIBNAME dataset optionsthat are usedto createor loadthe table, such as BULKLOAD=yes. (cid:0) Load process options for warehouse tables, such as GENERATION LEVEL and DROP INDEXES, are now surfaced through the WHPRCLDR type and all of its subtypes. For example, you can write a SAS/Warehouse Administrator add-in that reads the load options that are specified in a table’s load process and uses these options to load the corresponding table. (cid:0) The operating system and SAS version that are associated with a given host are now available through the WHHOST property. For example, you can write a SAS/Warehouse Administrator add-in that reads the host metadata that is associated with a given data store and then uses these values to generate code that is appropriate for the operating system and SAS version. (cid:0) You can now write OLAP objects through the metadata API. The following types have been updated: (cid:0) WHMDDSTR (cid:0) WHOLPSTC (cid:0) WHGRPOLP (cid:0) WHOLPTBL (cid:0) WHOLPMDD (cid:0) WHCOLOLP (cid:0) WHOLPDIM (cid:0) WHOLPHIR (cid:0) WHOLPCRS (cid:0) WHOLPCUB. 4 Prerequisites Chapter1 (cid:0) Metadata for columns that are selected using point and click in the Expression Builder and that are used in either a WHERE clause or a row selector is now surfaced through the WHSUBSET and WHROWSEL types. For example, you can write a SAS/Warehouse Administrator add-in that reads the column metadata that is associated with a WHERE clause or a row selector and uses this metadata to generate the appropriate code. (cid:0) You can now update the EXTENDED ATTRIBUTES property and other properties in the WHCOLTIM type. For example, you can use an add-in tool to add data mining attributes to a _LOADTM column, export the metadata for the table to Enterprise Miner and analyze the _LOADTM column in Enterprise Miner. (cid:0) The usage notes for the _UPDATE_METDATA_ method have been expanded. For details, see “Using _UPDATE_METADATA_” on page 46. Prerequisites To get the most out of this manual, you should be familiar with (cid:0) SCL (SAS Component Language), a programming language that controls SAS/AF applications and provides complete object-oriented programming constructs for creating an entire object-oriented application in SCL (cid:0) the SAS/AF software development environment (cid:0) SCL applications that use FRAME entries (cid:0) the SAS application whose metadata you want to read or write. To use the metadata API, you will need the following SAS products in addition to API software: (cid:0) Base SAS software, Release 6.12 or later (cid:0) SAS/AF software (cid:0) SAS/GRAPH software—if you need to modify or write API software that includes a GUI (cid:0) the SAS application whose metadata you want to read or write, such as SAS/Warehouse Administrator, Release 1.2 or later. SCL applications that use the metadata API must run under Release 6.12 or later of SAS. What is Metadata? Metadata is information that is internal to an application that describes elements in the application, such as tables and columns. Metadata can be divided into two main categories: Physical metadata specifies a set of software instructions that describe an application element. For example, the physical metadata for a SAS table might specify a certain number of rows and columns, with certain data transformations applied to some columns. Business metadata specifies text that describes the content or purpose of an application element. IntroductiontotheMetadataAPI HowtheMetadataAPIWorks 5 For example, the business metadata for a SAS table might describe the purpose of the table and contact information for the person responsible for the accuracy of the information in the table. Most SAS/Warehouse Administrator metadata contains information about data sources, data stores, and the jobs that extract, transform, and load source data into the warehouse data stores. SAS/Warehouse Administrator metadata is stored in two or more metadata repositories. What is the SAS/Warehouse Administrator Metadata API? It is a set of software tools that enable programmers to write applications that access metadata in SAS/Warehouse Administrator. What Can I Do with the SAS/Warehouse Administrator Metadata API? Using the metadata API, you can write programs that read, add, update, or delete the metadata in SAS/Warehouse Administrator—without going through the user interface. You can write SCL applications that (cid:0) publish HTML pages that contain the current metadata for a SAS/Warehouse Administrator group or data store (cid:0) change path names in metadata (cid:0) copy a table’s metadata (in order to create a similar table, for example) (cid:0) add columns to a table (cid:0) update a column attribute (cid:0) add tables and other objects that are defined by metadata (cid:0) use the API in a SAS macro to generate a LIBNAME statement. How the Metadata API Works Figure 1.1 on page 6 illustrates how client applications written in SCL use the metadata API to read or write metadata from SAS applications.

Description:
Using this reference, you can learn to write SAS Component Language (SCL) applications that publish HTML pages containing the current metadata for a data warehouse, change pathnames in metadata, add columns to a table, update a column attribute, add tables and other objects defined by metadata, and
See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.