Skip to Main Content

Past Tournament Quizzes

View your results and or take one of these quizzes now.

Filters

Expected format: YYYY-MM-DD
Expected format: YYYY-MM-DD

All Tournaments

Take
Quiz
View
Results
Ended
On
Feature / Summary / AuthorPlayed InCommentaryScore
2026-11-27 FridaySQL: BOOLEAN_AND_AGG

BOOLEAN_ANG_AGG (and the identical EVERY) function can be used to check (as aggregate or analytic function) if every row in a group satisfies a given boolean condition.

Author: Kim Berg Hansen [61039-10740009]
Weekly DBNo New Comments

Last: 2026-11-30 07:11:20
-
2026-11-20 FridaySQL: Windowing clause

The window clause, added in release 21c, enables you to define named windows to use in the over clause. It goes between the group by and row limiting clauses:

select … from … window <window_name> as ( <window> )

You can chain window definitions; though you can't extend an empty window definition.

Author: Chris Saxon [61019-10739991]
Weekly DBNo Comments
Last: No Comments
-
2026-11-13 FridaySQL: Datetime Expressions

With the large variety of ways to ‘add a year’ to a date, it is important to know what their assumptions are and how they deal with edge cases.

Author: Anthony Harper [60979-10738725]
Weekly DBNo Comments
Last: No Comments
-
2026-11-06 FridaySQL: DATEADD

The DATEADD function can add units of time to a DATE (or TIMESTAMP), which can be a nice alternative to adding numeric fractions of day or INTERVALs. But remember you cannot use DATEADD to add fractions of your time unit. For that, you'll often be better off using NUMTODSINTERVAL that supports fractions of time unit.

Author: Kim Berg Hansen [60999-10738937]
Weekly DBNo Comments
Last: No Comments
-
2026-10-30 FridaySQL: Aggregate Functions

The bit_*_agg functions, added in release 21c, run bitwise operations across the binary representation of their input numbers.

Author: Chris Saxon [60919-10738052]
Weekly DBNo Comments
Last: No Comments
-
2026-10-23 FridayOracle PL/SQL: Package invalidation and session state, the ORA-04068 error

Introduced in Oracle AI Database 23.26.0, the RESETTABLE clause can be used to allow a package to discard existing state during reinstantiation without raising the ORA-04068 error.

Author: Anthony Harper [60819-10736984]
Weekly DBNo Comments
Last: No Comments
-
2026-10-16 FridaySQL: Virtual columns

From version 23.7 a virtual column can be materialized, meaning it is not really virtual anymore, but the calculated expression is stored like if you had used a regular column with a trigger to maintain the value.

Author: Kim Berg Hansen [60959-10738047]
Weekly DBNo Comments
Last: No Comments
-
2026-10-09 FridaySQL: Domain DDL

Enumeration domains (enums) define a series of name-value pairs. This enables you to access the values by name in SQL.

Enums have a default display expression that converts the values to the corresponding name.

Author: Chris Saxon [60859-10737054]
Weekly DBNo Comments
Last: No Comments
-
2026-10-02 FridaySQL: Multi-table Inserts

There are many enhancements introduced for insert statements in Oracle 23.9 with multi row table value constructors, non-positional inserts and the insert set syntax.

Multi table inserts only support the insert set clause enhancement, and only for one row per insert into clause.

Author: Anthony Harper [60779-10735753]
Weekly DBNo Comments
Last: No Comments
-
2026-09-25 FridaySQL: GROUP BY ALL

GROUP BY ALL is a new 23.9 feature that makes it easier to group by every non-aggregate expression in the select list. But remember, it groups by entire expressions, not by columns within those expressions.

Author: Kim Berg Hansen [60799-10736374]
Weekly DBNo Comments
Last: No Comments
-
2026-09-18 FridaySQL: Analytic Functions

You can omit rows from window function calculations with the exclude clause. Added in release 21c, this has these options:

  • exclude no others => omit no rows (default)
  • exclude current row => omit the active row
  • exclude group => omit all rows with the same sort value as the active row
  • exclude ties => omit all other rows with the same sort value as the active row
Author: Chris Saxon [60759-10736110]
Weekly DBNo Comments
Last: No Comments
-
2026-09-11 FridaySQL: JSON_TRANSFORM Conditional RHS Path Expressions

Introduced in Oracle AI Database 26.2, Right Hand SIde (RHS) conditional path expressions for JSON_TRANSFORM using DECODe and CASE path expressions simplify transformation logic.  Learning how to use these path expressions allows for complex conditional logic in JSON_TRANSFORM without using the CASE operator.

Author: Anthony Harper [60639-10733776]
Weekly DBNo Comments
Last: No Comments
-
2026-09-04 FridaySQL: FISCAL

From version 23.26.1 there are a lot of functions available to make it easier to work with calendars, including fiscal calendars.

Author: Kim Berg Hansen [60599-10733157]
Weekly DBNo Comments
Last: No Comments
-
2026-08-28 FridaySQL: Data Manipulation Language Statements

Release 23.26.2 added a wait clause to all DML statements. The syntax for this is:

nowait | wait { forever | n [ seconds | milliseconds | microseconds ] }

The default is wait forever. When you specify nowait or a wait duration other than forever, the database raises an error if the DML is blocked by another transaction and it can't obtain the lock in the time specified.

Author: Chris Saxon [60659-10734195]
Weekly DBNo New Comments

Last: 2026-09-02 14:45:55
-
2026-08-21 FridaySQL: Nested With Clause

As of Oracle AI Database 23.26.2, subquery factoring clauses can be nested with some restrictions.  

Set operations (UNION, MINUS, INTERSECT) and recursive subqueries are both restricted.

It is possible to workaround the set operator restriction using inline views.

Author: Anthony Harper [60559-10730793]
Weekly DBNo Comments
Last: No Comments
-
2026-08-14 FridayOracle PL/SQL: Labeling a PL/SQL Loop

It's often a good idea to label your loops, particularly if they're nested and/or much code within the loop. You can use the label in EXIT statements.

You can also make your code more readable by specifying the loop label in the END LOOP statement so you can see which loop it is that ends right here in the code. However, that is just for readability, the compiler does not check whether you specify or correct loop label or not in END LOOP.

Author: Kim Berg Hansen [60578-10730757]
Weekly DBNo Comments
Last: No Comments
-
2026-08-07 FridayDatabase Design: JSON Data Type

The JSON data type, added in release 21c, optimizes querying and updating JSON data.

Release 26ai extended this with type modifiers, enabling you to state whether the JSON values are objects, arrays, or scalars.

Author: Chris Saxon [60598-10731748]
Weekly DBNo Comments
Last: No Comments
-
2026-07-31 FridaySQL: JSON Path Expressions

JSON Path conditional expressions using case and decode were introduced in Oracle AI Database 26.2

Author: Anthony Harper [60518-10729493]
Weekly DBNo Comments
Last: No Comments
-
2026-07-24 FridayOracle PL/SQL: PRAGMA SUPPRESSES_WARNING_6009

You can help yourself avoid some potential bugs by setting your database to throw a compile time error if you have a WHEN OTHERS exception block in your code that does not re-raise an error.

But what do you then do for those very rare cases where it is actually on purpose to have a WHEN OTHERS without a RAISE, if the database then throws an error? You can use PRAGMA SUPPRESSES_WARNING_6009 to create a procedure or function that the compiler will accept as an alternative to RAISE or RAISE_APPLICATION_ERROR.

Author: Kim Berg Hansen [60560-10730117]
Weekly DBNo Comments
Last: No Comments
-
2026-07-17 FridaySQL: Domain DDL

Added in release 26ai, usecase domains help you describe values. A single column domain has a data type and many optional properties including:

  • strict (the domain and table column's data types must match exactly)
  • default value
  • not null constraint
  • collate
  • check constraint
Author: Chris Saxon [60500-10729522]
Weekly DBNo New Comments

Last: 2026-07-20 14:11:56
-
2026-07-10 FridaySQL: DATEDIFF

Function DATEDIFF give us an easy way to determine number of years, months, hours (or basically any time unit) between two dates.

Author: Kim Berg Hansen [60501-10729102]
Weekly DBNo New Comments

Last: 2026-07-15 06:00:57
-
2026-07-03 FridayOracle PL/SQL: Datetime Functions

System time functions in an SQL query will always return the time when the query began executing.

To report row by row timing information for a time intensive process in SQL it is necessary to leverage PL/SQL functionality.

Author: Anthony Harper [50769-10724495]
Weekly DBNo Comments
Last: No Comments
-
2026-06-26 FridaySQL: PHONIC_ENCODE

Added in 23.4, you can use phonic_encode to do sounds like matching. This can use the standard and alternate double metaphone algorithms to encode strings based on their pronunciation.

Author: Chris Saxon [60376-10727573]
Weekly DBNo Comments
Last: No Comments
-
2026-06-19 FridayOracle PL/SQL: Vector Distance Functions

The Hamming vector distance metric is available in PL/SQL, but only as a metric specification for the VECTOR_DISTANCE function.  

The HAMMING_DISTANCE function is not supported in PL/SQL for comparing binary vectors.

Author: Anthony Harper [60236-10724472]
Weekly DBNo Comments
Last: No Comments
-
2026-06-12 FridaySQL: GRAPH_TABLE Operator

A property graph can be used as an alternative to hierarchical queries. If you wish, you can setup duplex edges, which can make your code more self-documenting.

Author: Kim Berg Hansen [60336-10726497]
Weekly DBNo New Comments
Objections:
Last: 2026-06-07 16:00:24
-
2026-06-05 FridaySQL: Assertion DDL

Oracle AI Database 23.26.1 added assertions. These enable you to create cross-row constraints. The basic syntax for these is:

create assertion <assertion_name> check ( <Boolean expression> )

The Boolean expression can use exists, not exists, or the new all … satify expression.

Author: Chris Saxon [60296-10725765]
Weekly DBNo Comments
Last: No Comments
-
2026-05-29 FridaySQL: Filtered Aggregation

Filtered Aggregates, introduced in 26.1 simplify the syntax required to aggregate different elements of groupings independently.

Author: Anthony Harper [60196-10722646]
Weekly DBNo Comments
Last: No Comments
-
2026-05-22 FridaySQL: QUALIFY Clause

Just like we are used to using HAVING clause like a “where” clause on the results of aggregate functions, from version 23.26.0 we can use the QUALIFY clause like a “where” clause on the results of analytic functions.

Author: Kim Berg Hansen [60216-10723650]
Weekly DBNo New Comments

Last: 2026-05-20 22:10:42
-
2026-05-15 FridaySQL: GRAPH_TABLE Operator

The graph_table operator, added in 26ai, enables you to traverse graphs using SQL. You can match a variable number of edges between to points in the graph with regular expression-like {m,n} syntax. This finds a route with at least m and and most n rows.

Author: Chris Saxon [60176-10722763]
Weekly DBNo Comments
Last: No Comments
-
2026-05-08 FridaySQL: Datetime Format Models

ISO week numbers are not always sequential week numbers.  A simple user request can have hidden complexity that requires analytics to solve.

Author: Anthony Harper [50589-10720906]
Weekly DBNo New Comments

Last: 2026-05-03 20:06:51
-
2026-05-01 FridaySQL: Boolean Expressions

Using boolean expressions can both simplify and clarify your code.

Author: Kim Berg Hansen [60138-10720986]
Weekly DBNo New Comments

Last: 2026-04-29 18:54:47
-
2026-04-24 FridaySQL: Table DDL

Oracle AI Database 26ai introduced the if [not] exists clause for DDL statements. This works as follows:

  • create … if not exists … => no action or error if there is already an object with this name in the schema.
  • alter … if exists … => no action or error if there is not an object with this name in the schema.
  • drop … if exists … => no action or error if there is not an object with this name in the schema.
Author: Chris Saxon [60115-10720982]
Weekly DBNo New Comments

Last: 2026-04-18 11:23:08
-
2026-04-17 FridayOracle PL/SQL: Cursor Iteration Controls

A collection can be populated using a cursor iteration control as a qualified expression.  If the iteration control is based on a weak cursor variable, the iterator type must be defined.

Author: Anthony Harper [60135-10720833]
Weekly DBNo Comments
Last: No Comments
-
2026-04-10 FridayOracle PL/SQL: ENCODE

UTL_URL.ENCODE can URL encode a string in multiple ways - you need to think about the values you pass in to the parameters of the function.

Take particular note that the parameter for characterset behaves a bit different than many functions. You're probably used to passing a NULL behaves the same as not passing a value (ie. relying on the default.) This is not the case here, where a NULL means database character set, while the default is the characterset of UTL_HTTP.GET_BODY_CHARSET, which currently defaults to ISO-8859-1.

Author: Kim Berg Hansen [60075-10720247]
Weekly DBNo Comments
Last: No Comments
-
2026-04-03 FridaySQL: QUALIFY Clause

Oracle AI Database release 23.26.0 introduced the qualify clause. This enables you to filter the output of window functions.

Author: Chris Saxon [60055-10719502]
Weekly DBNo Comments
Last: No Comments
-
2026-03-27 FridaySQL: Filtered Aggregation

Oracle AI Database 23.26.1.0 Introduced support for filtered aggregates, simplifying aggregation of different elements within the same grouping.

Author: Anthony Harper [59995-10717543]
Weekly DBNo Comments
Last: No Comments
-
2026-03-20 FridaySQL: UUID_TO_RAW

UUID_TO_RAW provides an easy way to turn a UUID string into RAW, no matter which of the 4 supported syntaxes the string is using. If you don't want an error raised on invalid UUID values, test with IS_UUID before converting.

Author: Kim Berg Hansen [60035-10718476]
Weekly DBNo Comments
Last: No Comments
-
2026-03-13 FridaySQL: INSERT Statement

Oracle AI Database release 23.9 introduced non-positional inserts. This enables update-like set clauses for insert statements.

insert into <table_name>
set    <column_name> = <value>, <column_name> = <value>, ...

You can load many rows in one non-positional insert. To do this, wrap each row with parentheses and place a comma between each row.

Author: Chris Saxon [59975-10717626]
Weekly DBNo Comments
Last: No Comments
-
2026-03-06 FridayOracle PL/SQL: Guidelines for Boolean Expressions

The IS [NOT] TRUE boolean test condition is only valid syntax in SQL.  In PL/SQL the same test has to use the equality operator.

Author: Anthony Harper [59935-10716429]
Weekly DBNo Comments
Last: No Comments
-
2026-02-27 FridayOracle PL/SQL: Iteration Controls

Iteration controls allow us in many situations to create concise and simple logic without needing extraneous variables and code.

Author: Kim Berg Hansen [59915-10715936]
Weekly DBNo Comments
Last: No Comments
-
2026-02-20 FridaySQL: Analytic Functions

Oracle Database 21c, introduced the groups frame for window functions. This is a hybrid between rows physical offsets and range logical offsets:

  • Rows with the same value for the sort keys are in the same group, like range.
  • Offsets are calculated as the number of groups, like rows.
Author: Chris Saxon [59876-10715387]
Weekly DBNo Comments
Last: No Comments
-
2026-02-13 FridaySQL: Multicolumn Usecase Domains

Creating a use case domain with a domain order function standardizes the ordering of queries on tables using the domain without duplicating the order clasue in each SQL statement.

Author: Anthony Harper [59835-10714620]
Weekly DBNo Comments
Last: No Comments
-
2026-02-06 FridaySQL: Date, Timestamp and Interval Types

CAST of a TIMESTAMP WITH TIME ZONE to a DATE (whether explicit or implicit) simply removes the time zone information from the value. If you instead want your DATE to contain the timestamp value with time zone converted to for example the database time zone, you need to first convert, then cast.

Author: Kim Berg Hansen [59877-10714874]
Weekly DBNo New Comments

Last: 2026-02-09 07:14:44
-
2026-01-30 FridayOracle PL/SQL: The FOR LOOP Statement

Release 21c of Oracle AI Database extended for loops in PL/SQL. New options include:

  • by - specify a custom increment
  • when <condition> - only run the loop body if the condition is true
  • A comma-separated list of values to loop through
Author: Chris Saxon [59795-10714205]
Weekly DBNo Comments
Last: No Comments
-
2026-01-29 ThursdayDatabase Administration: Statistics

From release update 23.8, the optimizer can gather dynamic stats for table function calls. This can give better row estimates. 

You can control this with:

  • The global PL/SQL dynamic_stats preference
  • The dynamic_stats function preference
  • The parameter plsql_function_dynamic_stats

The priority of these (from highest to lowest) is:

plsql_function_dynamic_stats > Function preference > Global preference

Author: Chris Saxon [59815-10714274]
Oracle Database Annual ChampionshipNo Comments
Last: No Comments
-
2026-01-29 ThursdaySQL: GRAPHQL Table Function

GraphQL is an alternative way to query data and retrieve JSON than using SQL. You can use the table function GRAPHQL to use GraphQL syntax within Oracle database.

Author: Kim Berg Hansen [59195-10713027]
Oracle Database Annual ChampionshipNo Comments
Last: No Comments
-
2026-01-29 ThursdayOracle PL/SQL: Calling Macros From PLSQL

SQL Macros used in PL/SQL methods are resolved at compile time.

Author: Anthony Harper [59776-10713152]
Oracle Database Annual ChampionshipNo New Comments

Last: 2026-02-01 15:35:29
-
2026-01-29 ThursdaySQL: Hidden and Generated Fields

Hidden and generated fields in version 23.6 gives you more flexibility for read-only attributes of JSON Relational Duality Views.

Author: Kim Berg Hansen [59735-10713069]
Oracle Database Annual ChampionshipNo Comments
Last: No Comments
-
2026-01-29 ThursdaySQL: JSON_TRANSFORM

It is possible to pass multiple arguments in a single bind variable with the PASSING clause if the bind variable is using JSON datatype.

Author: Anthony Harper [59655-10713063]
Oracle Database Annual ChampionshipNo Comments
Last: No Comments
-
2026-01-29 ThursdaySQL: FUZZY_MATCH

Oracle AI Database added the fuzzy_match operator. This supports several fuzzy matching algorithms:

  • LEVENSHTEIN corresponds to UTL_MATCH.EDIT_DISTANCE or UTL_MATCH.EDIT_SIMILARITY and gives a measure of character edit distance or similarity.
  • DAMERAU_LEVENSHTEIN distance differs from the classical LEVENSHTEIN distance by including transpositions among its allowable operations in addition to the three classical single-character edit operations (insertions, deletions and substitutions).
  • JARO_WINKLER corresponds to UTL_MATCH.JARO_WINKLER (a percentage between 0-1) or UTL_MATCH.JARO_WINKLER_SIMILARITY (the same but scaled from 0-100).
  • BIGRAM and TRIGRAM are instances of the N-gram matching technique, which counts the number of common contiguous substrings (grams) between the two strings.
  • WHOLE_WORD_MATCH corresponds to Word Match Percentage or Count comparison in Oracle Enterprise Data Quality. It calculates the LEVENSHTEIN or edit distance of two phrases with words (instead of letters) as matching units.
  • LONGEST_COMMON_SUBSTRING finds the longest common substring between the two strings.
Author: Chris Saxon [59715-10714024]
Oracle Database Annual ChampionshipNo Comments
Last: No Comments
-
  • 1 - 50