SQL for
Analysis, Reporting
and Modeling

 

Included in Oracle Database 12c Release 2 is a compelling array of analytical features and functions that are accessible through SQL.

What's New in Database 12c Release 2

There are many new features and enhancements in 12.2 that extend Oracle's flexible and comprehensive analytical framework:
  • Enhancements to LISTAGG to manage extremely large lists and control errors
  • New VALIDATE_CONVERSION function to detect if an input value can be converted to destination type
  • Enhancements to CAST function to return a user-specified value instead of an error
  • New approximate query processing for percentiles and MEDIAN functions
  • New approximate processing to support reusable aggregations and materialized views
Overall, the SQL analytic functions and features in Oracle Database 12c Release 2 make it the most effective platform for delivering analytical results directly into operational, data warehousing and business intelligence projects. For more information see the following:


Whitepaper: SQL For Data Warehousing and Analysis: What's New In Oracle Database 12c Release 2

Presentation OpenWorld 2016, Oracle Database 12c Release 2: Top 10 Data Warehouse Features for Developers and DBAs


Try out these new features today by using the new Express Express Cloud Service and requesting a free trial subscription.

Oracle Database Exadata Express Cloud Service - with this service you get your own Oracle Database 12c Release 2 Enterprise Edition plus options running on Exadata in Oracle Cloud.


Back to top


Overview of SQL for Analysis, Reporting and Modeling

The in-database analytical functions and features that are embedded inside the Oracle Database can be used to answer a wide variety of business problems. Developers and business users can access a wide range of analytic features and combine their results with other SQL queries and analytical pipelines to gain deeper insights.

Oracle's Database includes the following features:

  • Ranking
  • Analytical windows
  • Reporting aggregates
  • LAG/LEAD
  • FIRST/LAST
  • Statistics library
  • Hypothetical Rank and Distribution
  • Approximate query processing
  • Pattern matching
  • Modeling
  • Advanced aggregations
  • User defined functions

Standards Based SQL
In 1986, SQL became a standard of the American National Standards Institute (ANSI) and since then it has advanced to its current iteration, ANSI 2011. This standardization has two major benefits:
- the standard provides a high degree of application portability across different database systems without major code changes. In the field of data warehousing, BI tools are able to effectively support multiple types of SQL databases in a straightforward manner.

- the SQL standard has ensured continuity in application development. A SQL statement written thirty years ago continues to run today, without any modification to the SQL code.

Continuous Evolution
Oracle has a long history of embedding sophisticated SQL-based analytics within the Oracle Database.

Window functions, which are now a key analytical feature in the analysis of big data, were first introduced in Oracle 8i (1999) and many developers use them to manage complex big data requirements.

Oracle 10g (2003) introduced the SQL Model clause, which provides a spreadsheet-like what-if modeling framework aimed at business users and 12c introduced SQL pattern matching along with the HyperLogLog based approximate count distinct function.

Back to top

Key Benefits

The key benefits provided by Oracle's in-database analytical functions and features are:

Enhanced Developer Productivity - perform complex analyses with much clearer and more concise SQL code. Complex tasks can now be expressed using single SQL statement which is quicker to formulate and maintain, resulting in greater productivity.

Improved Query Speed - processing optimizations supported by in-database analytics enable significantly better query performance. Actions which before required self-joins or complex procedural processing may now be performed in native SQL.

Improved Manageability - ability to access a consolidated view of all data types and sources is simplified when applications share a common relational environment rather than a mix of calculation engines with incompatible data structures.

Minimized Learning Effort - SQL analytic functions minimize the need to learn new keywords because the syntax leverages existing well-understood keywords.

Industry standards based syntax - Oracle's features conform to ANSI SQL standard and are supported by a large number of independent software vendors.