From b5fab19683c7fc3690b64a9db4fea54e350e74c9 Mon Sep 17 00:00:00 2001 From: asfernandes Date: Tue, 8 May 2007 02:31:11 +0000 Subject: [PATCH] Misc --- src/common/classes/tree.h | 10 +++++----- src/dsql/parse.y | 4 +++- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/common/classes/tree.h b/src/common/classes/tree.h index 852970b239..5f8e185df4 100644 --- a/src/common/classes/tree.h +++ b/src/common/classes/tree.h @@ -175,14 +175,14 @@ public: (level == 0 && ((ItemList*)root)->getCount() == 0); } - bool add(const Value& item) {return defaultAccessor.add(item); } + bool add(const Value& item) { return defaultAccessor.add(item); } class Accessor; // If item already exists method sets accessor's current position - // to found item's location and returns false + // to found item's location and returns false. // If item not exists method will add it to the tree and return true, - // not touching accessor's current position - bool add(const Value& item, Accessor *accessor); + // not touching accessor's current position. + bool add(const Value& item, Accessor* accessor); // Remove item. Current position moves to next item after this call. // If next item doesn't exist method returns false @@ -575,7 +575,7 @@ private: /************************ BePlusTree implementation ******************/ template -bool BePlusTree::add(const Value& item, Accessor *accessor) +bool BePlusTree::add(const Value& item, Accessor* accessor) { // Finish initialization of the tree if necessary if (!root) root = new (pool->allocate(sizeof(ItemList))) ItemList(); diff --git a/src/dsql/parse.y b/src/dsql/parse.y index 718a159676..8f24debe7c 100644 --- a/src/dsql/parse.y +++ b/src/dsql/parse.y @@ -3205,6 +3205,7 @@ with_list : with_item { $$ = make_node (nod_list, 2, $1, $3); } ; +// ASF: Create derived table with nested union to fix CORE-1246 with_item : symbol_table_alias_name derived_column_list AS '(' select_expr ')' { $$ = make_node (nod_derived_table, (int) e_derived_table_count, make_node (nod_select_expr, (int) e_sel_count, make_node(nod_list, 1, $5), NULL, NULL, NULL), @@ -3316,7 +3317,8 @@ table_primary : table_proc { $$ = $2; } ; -/* AB: derived table support */ +// AB: derived table support +// ASF: create derived table with nested union to fix CORE-1246 derived_table : '(' select_expr ')' as_noise correlation_name derived_column_list { $$ = make_node(nod_derived_table, (int) e_derived_table_count,