Chapter 7: Advanced Queries


Overview

In this chapter, you will

  • Learn how to use the set operators, which allow you to combine rows returned by two or more queries.

  • Use the TRANSLATE() function to convert characters in one string to characters in another string based on a set of translation characters .

  • Use the DECODE() function to search a set of values for a certain value.

  • Learn how to use the CASE expression to perform if-then-else logic in SQL without having to use PL/SQL. (You ll learn how to use PL/SQL in Chapter 11.)

  • Learn how to perform queries against data that is organized into a hierarchy.

  • Use the ROLLUP clause to return rows containing a subtotal for each group .

  • Use the CUBE clause to return rows containing a subtotal for all combinations of columns along with a total at the end.

  • Learn about the analytic functions that enable you to perform complex calculations such as finding the top-selling product type for each month, the top salespersons, and so on.

  • Use the new Oracle Database 10 g MODEL clause to perform inter-row calculations.

Let s plunge in and examine the set operators.




Oracle Database 10g SQL
Oracle Database 10g SQL (Osborne ORACLE Press Series)
ISBN: 0072229810
EAN: 2147483647
Year: 2004
Pages: 217

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net