8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 00:03:02 +01:00
This commit is contained in:
asfernandes 2007-05-08 02:31:11 +00:00
parent ccf737df89
commit b5fab19683
2 changed files with 8 additions and 6 deletions

View File

@ -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 <typename Value, typename Key, typename Allocator, typename KeyOfValue, typename Cmp, int LeafCount, int NodeCount>
bool BePlusTree<Value, Key, Allocator, KeyOfValue, Cmp, LeafCount, NodeCount>::add(const Value& item, Accessor *accessor)
bool BePlusTree<Value, Key, Allocator, KeyOfValue, Cmp, LeafCount, NodeCount>::add(const Value& item, Accessor* accessor)
{
// Finish initialization of the tree if necessary
if (!root) root = new (pool->allocate(sizeof(ItemList))) ItemList();

View File

@ -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,