* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Download Course Title> - dbmanagement.info
Survey
Document related concepts
Transcript
Building the Physical Layer of a Repository Copyright © 2007, Oracle. All rights reserved. Objectives After completing this lesson, you should be able to: • Identify and describe the objects in the Physical layer of a repository • Create the Physical layer of a repository 2-2 Copyright © 2007, Oracle. All rights reserved. Physical Layer • Contains objects representing the physical data sources to which Oracle BI Server submits queries • May contain multiple data sources • Is typically the first layer built in the repository Data sources 2-3 Copyright © 2007, Oracle. All rights reserved. Physical Layer Objects Are objects in the Physical layer, such as connection pools, folders, tables, columns, and keys • Expand a database object to display the objects it contains. Database Connection pool Schema folder Tables Columns Key 2-4 Copyright © 2007, Oracle. All rights reserved. Database Object • Is the highest-level object in the Physical layer • Defines the data source to which Oracle BI Server submits queries Database object 2-5 Copyright © 2007, Oracle. All rights reserved. Database Object: General Properties Use the General tab to view and set general properties for a database object. Name Type 2-6 Copyright © 2007, Oracle. All rights reserved. Database Object: Features Use the Features tab to view and set the SQL features that Oracle BI Server uses with this data source. Enable or disable feature 2-7 Copyright © 2007, Oracle. All rights reserved. Default SQL features for this data source Connection Pool • Defines how Oracle BI Server connects to a data source • Specifies the ODBC or native data source name • Allows multiple users to share a pool of data source connections Connection pool name Maximum number of connections Data source name Shared logon user name and password 2-9 Copyright © 2007, Oracle. All rights reserved. Connection pooling enabled Schema Folder Is an optional display folder that contains tables and columns for a physical schema • To create a schema folder, right-click a database object and select New Object > Physical Schema. Schema folder 2 - 10 Copyright © 2007, Oracle. All rights reserved. Physical Table • Is an object that corresponds to a table in a physical data source • Is typically imported from a database or other data source • Provides the metadata necessary for Oracle BI Server to access the tables with SQL requests Physical table 2 - 11 Copyright © 2007, Oracle. All rights reserved. Physical Table Properties Double-click a physical table object to view its properties: Use tabs to create, view, or modify other properties. Name Table type Cacheable 2 - 12 Copyright © 2007, Oracle. All rights reserved. Physical Table: Alias Table Type Is a virtual physical table object that points to a physical table object • Right-click a physical table and select New Object > Alias. • Provide a name for the alias table. • The alias table appears with an alias icon in the Physical layer. Alias name Source table 2 - 13 Alias synchronization is automatic. Copyright © 2007, Oracle. All rights reserved. Physical Table: Select Table Type Specifies that a physical table object is a SELECT statement Table Type Database specific SQL SELECT statement 2 - 14 Copyright © 2007, Oracle. All rights reserved. Physical Table: View Deployment Creates a corresponding database view for metadata views Select Deploy View. View created in database 2 - 15 Copyright © 2007, Oracle. All rights reserved. Physical Column Is an object that corresponds to a column in a physical database Columns 2 - 16 Copyright © 2007, Oracle. All rights reserved. Key Column Defines relationships between tables • Primary key: – Uniquely identifies a single row of data – Consists of a column or set of columns – Is identified by a key icon • Foreign key: – Refers to the primary key columns in another table – Is composed of a column or set of columns Key 2 - 17 Copyright © 2007, Oracle. All rights reserved. Joins Represent the primary key–foreign key relationships between tables in the Physical layer Join properties Physical Diagram Double-click to view join properties. Join expression 2 - 18 Copyright © 2007, Oracle. All rights reserved. ABC Scenario Data for ABC resides in the SUPPLIER2 schema in an Oracle relational database, containing tables with: • Invoice data • Customer data Physical layer • Product data • Period data Source data 2 - 19 SUPPLIER2 Import metadata using Administration Tool Copyright © 2007, Oracle. All rights reserved. Implementation Steps 1. 2. 3. 4. 5. 6. 7. 2 - 20 Define an ODBC System Data Source Name (DSN). Import the physical schema. Select tables and columns for import. Import keys and joins. Verify the import. Edit connection pool properties. Define physical keys and joins. Copyright © 2007, Oracle. All rights reserved. 1. Define an ODBC System DSN Use the ODBC Data Source Administrator to define a system DSN for each data source. Data source name TNS service name Test User ID 2 - 21 Copyright © 2007, Oracle. All rights reserved. 2. Import the Physical Schema Use the Oracle BI Administration Tool to import the physical schema. Select ODBC source. Select File > Import > from Database. 2 - 22 Copyright © 2007, Oracle. All rights reserved. 3. Select Tables and Columns for Import Select the tables and columns needed to support the business model. Filter tables for import. Select tables or columns for import. Tables and keys selected by default 2 - 23 Copyright © 2007, Oracle. All rights reserved. 4. Import Keys and Joins Keys, foreign keys, and corresponding joins are imported automatically only if they are already defined in the data source. 2 - 24 Copyright © 2007, Oracle. All rights reserved. 5. Verify the Import • Verify that the correct schema, tables, columns, and keys were imported. • Use Update Row Count and View Data features to verify connection. Schema Tables Columns Key 2 - 25 Copyright © 2007, Oracle. All rights reserved. 6. Edit Connection Pool Properties After import, verify or modify connection pool properties using the connection pool properties dialog box. Connection pool name Call interface Maximum number of connections Shared logon user name and password Data source name Connection pooling enabled 2 - 26 Copyright © 2007, Oracle. All rights reserved. 7. Define Physical Keys and Joins The Administration Tool allows you to define physical keys and joins that were not imported automatically. • Define keys using the Physical Table properties dialog box. • Define joins and keys using the Physical Diagram. 2 - 27 Copyright © 2007, Oracle. All rights reserved. Defining Keys Using the Table Properties Dialog Open the table properties dialog box to view or define keys. Select the appropriate tab. Check the appropriate check box to define the key. Click New. 2 - 28 Copyright © 2007, Oracle. All rights reserved. Using the Physical Diagram Use the Physical Diagram to view or define keys and joins. Click the Physical Diagram icon ... ... or right-click the object to open the Physical Diagram. Double-click the link to open the Joins properties box. 2 - 29 Copyright © 2007, Oracle. All rights reserved. Defining Foreign Key Joins 1. Select New Foreign Key. 5. Select key columns. 2. Select “one” table in relationship. 3. Select "many” table in relationship. 4. Physical Foreign Key dialog opens. 6. Join expression: first table selected maintains primary key; second table selected maintains foreign key to first table. 2 - 30 Copyright © 2007, Oracle. All rights reserved. Summary In this lesson, you should have learned how to: • Identify and describe the objects in the Physical layer of a repository • Create the Physical layer of a repository 2 - 31 Copyright © 2007, Oracle. All rights reserved. Practice 2-1 Overview: ABC Business Scenario This practice covers the ABC business scenario. 2 - 32 Copyright © 2007, Oracle. All rights reserved. Practice 2-2 Overview: Gathering Information to Build an Initial Business Model This practice covers the following topics: • Gathering and analyzing the business requirements of the ABC company • Determining the structure of the initial business model 2 - 33 Copyright © 2007, Oracle. All rights reserved. Practice 2-3 Overview: Creating a Repository and Importing a Data Source This practice covers the following topics: • Creating a new repository • Import tables into the Physical layer of the repository 2 - 34 Copyright © 2007, Oracle. All rights reserved. Practice 2-4 Overview: Defining Keys and Joins This practice covers the following topic: • Defining the primary keys, foreign keys, and joins in the Physical layer using the Administration Tool 2 - 35 Copyright © 2007, Oracle. All rights reserved. Practice 2-5 Overview: Creating Alias and Select Tables This practice covers the following topics: • Creating an alias table • Creating a select table • Deploying a view 2 - 36 Copyright © 2007, Oracle. All rights reserved.