db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Db-derby Wiki] Update of "OLAPNullOrdering" by BryanPendleton
Date Fri, 20 Jul 2007 16:01:37 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Db-derby Wiki" for change notification.

The following page has been changed by BryanPendleton:

   * The new syntax must be added to the SQL grammar
   * The null ordering specification must be passed around through the compiler data structures
so that it eventually gets passed to the sorter. This involves data structures like {{{OrderByList}}}
and {{{OrderByColumn}}}. Eventually, the compiler must set up the correct {{{ColumnOrdering}}}
objects, which I think happens in {{{RowOrderingImpl.addOrderedColumn}}}
+  * The data structure which bridges the gap between the compiler and the execution code
is the {{{IndexColumnOrder}}} class. This class is used both for describing ORDER BY sorts
for queries, as well as for describing the sorts used when creating indexes. Since indexes
in Derby will remain unconditionally NULLS LAST, the index-creation callers of the {{{IndexColumnOrder}}}
class will specify NULLS LAST unconditionally, while the query compilation callers will specify
either NULLS FIRST or NULLS LAST depending on what was specified in the query.
   * The sorter must be changed so that in addition to having a columnOrderingMap and a columnOrderingAscendingMap,
it also has a columnOrderingNullOrderingMap, where it records the NULLS FIRST or NULLS LAST
specification for each column in the sort.
   * The sorter must pass the user's choice to the DataValueDescriptor.compare() method call.
   * The DataValueDescriptor.compare(DataValueDescriptor other) method must be changed to
allow the null ordering choice to be passed in

View raw message