optional Select the Case-sensitive check box to match upper and lowercase To select the values that you want in the Displayed values list, move LOV

21-24 Oracle Fusion Middleware Users Guide for Oracle Business Intelligence Discoverer Plus ■ Departments ■ Employees ■ Locations The figure below shows that the Department table is a master table to the Employees table and the Locations table in a relational one to many 1:M relationship. Figure 21–8 A database with three tables Each employee is associated with a single department because each employee works in only one department. In addition, each employee can only be based in one location. However, departments are associated with multiple locations because departments can have offices in different cities. Consequently, because of the mutual association of employees and locations with the Departments table, employees become unintentionally associated with multiple locations. This is incorrect because employees can only be in one location. For example, a query to count the number of employees at each location and department produces an incorrect result. The same employee is counted at multiple locations because the departments are at multiple locations. In the example below, the real number of employees is four, but the query produces a count of eight employees. Clark, Miller, and Scott are counted for both London and Tokyo, and King is counted for both Amsterdam and San Francisco. The figure below shows how a query to return the number of employees returns eight rows in a fan trap relationship instead of four rows. Advanced Discoverer Plus Relational Features 21-25 Figure 21–9 Fan trap query results Key to figure: a. Query to count the number of employees returns this data. When you create a worksheet, Discoverer automatically detects and resolves fan traps. If the fan trap is not resolvable, Discoverer disallows the worksheet and displays an error message. For more information about enabling and disabling fan trap detection in Discoverer, see the Options dialog: Advanced tab . About multiple join paths When you create new worksheets, the data items in the worksheets are often stored in multiple folders in the database. Discoverer checks to ensure that: ■ multiple folders have an unambiguous relationship between them ■ the relationships between data items is also unambiguous Multiple join paths occur when two tables can be linked in multiple ways. For example, a sales order table might be linked to a customer table on the Customer ID field, because both tables contain the field Customer ID. If both tables also contain a field called Location, this provides an alternative join path for the two tables. This is an example of a multiple join path. Multiple join paths occur when databases are organized so that the relationships between items in different tables are ambiguous. When you create new worksheets, Discoverer can automatically detect and warn you if potential multiple join paths exist. This makes sure that you always get the results that you expect, because you do not associate items in a way that you did not intend. Multiple join path warnings are not error messages. The warnings merely advises you that the database contains ambiguous relationships. If warnings occur, contact the Discoverer manager who can determine whether the database’s organization must be modified. Note : To detect and resolve multiple join paths, ensure that the Disable Multiple Join Path Detection option is not selected on the Options dialog: Advanced tab . 21-26 Oracle Fusion Middleware Users Guide for Oracle Business Intelligence Discoverer Plus Using SQL This section is aimed at experienced Discoverer users and managers who are familiar with SQL Structured Query Language and who are interested in Discoverer’s advanced facilities. This section contains the following topics: ■ What is SQL ■ Why should I be interested in SQL? ■ About the Discoverer execution plan ■ How to view SQL ■ How to view a SQL execution plan What is SQL SQL is a generic programming language used to extract and manipulate data in a database. In other words, SQL enables you to ask a question known as a query of the database that the database answers by displaying data. For example, you might use SQL to ask the question Which products sell more than 10,000 per year?. The database uses SQL to return a list of products that sell more than 10,000, and might also perform other analysis such as sorting, grouping, and totalling of the data. SQL is a powerful language, but is difficult to learn and use. Although Discoverer itself uses SQL to display and analyze worksheet data, Discoverer users are shielded from underlying SQL. Why should I be interested in SQL? Because Discoverer shields Discoverer users from underlying SQL, they do not need to know how SQL works. So, users with no technical database experience and no knowledge of underlying database structures can perform sophisticated data analysis. However, in some circumstances, you might want to look at SQL being used by Discoverer. For example, to improve Discoverer performance you might have to look at underlying SQL to ensure that queries are being run efficiently. What are summaries? Summaries are database tables that contain commonly accessed, pre-processed data, which gives the following benefits: ■ because data is pre-joined and pre-aggregated, Discoverer can access this data more quickly than by using ad hoc query ■ this also means that the data is processed once and accessed many times, rather than re-processed every time it is needed What are summary folders A summary folder is how Discoverer represents an underlying summary or materialized view. Summaries and materialized views pre-compute and store aggregated data for use in SQL queries. Advanced Discoverer Plus Relational Features 21-27 Summaries are created by the Discoverer manager to improve the performance of Discoverer, to help do your work more quickly and efficiently. Summary tables and materialized views are created as follows: ■ a summary table is a table that Discoverer creates. ■ a materialized view is the database server’s own summary mechanism. What is an execution plan? An execution plan is a sequence of operations that the Oracle Server performs to execute a SQL statement. About the Discoverer execution plan When looking at the underlying SQL that Discoverer is using, use the Discoverer execution plan tab to look the underlying execution plan being used. You can look at an execution plan to see how a SQL statement is being executed. For example, when using Summaries, you might want to check that a query is using a summary or materialized view created by the Discoverer manager. How to view SQL You view SQL created by Discoverer when you want to see the underlying SQL instructions that Discoverer is using to display the current worksheet. To view SQL created by Discoverer: 1. Choose Tools | Show SQL to display the SQL Inspector dialog. 2. Display the SQL tab to look at the underlying SQL. 3. optional To copy the SQL text into memory, click Copy. You can then switch to a different application and paste in the text. For example, you might want to paste this text into a text editor, edit the text, then save in a SQL file to that you can execute the file using SQLPlus. 4. Click OK to close the SQL Inspector dialog and return to the worksheet. Note : The SQL Inspector dialog might show a shortened version of the SQL that Discoverer sends to the RDBMS. Depending on how Discoverer is configured, inline views might be removed to make the SQL statement more legible. Contact the