Below is the list of changes that have just been committed into a local
5.0 repository of schwenke. When schwenke does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.1917 05/08/01 08:34:29 schwenke@stripped +1 -0
Merge aschwenke@stripped:/home/bk/mysql-5.0
into alpha.xl.local:/home/schwenke/Work/MySQL/BK-internal-tree/mysql-5.0
sql/sql_select.cc
1.348 05/08/01 08:31:12 schwenke@stripped +0 -0
Auto merged
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: schwenke
# Host: alpha.xl.local
# Root: /home/schwenke/Work/MySQL/BK-internal-tree/mysql-5.0/RESYNC
--- 1.347/sql/sql_select.cc 2005-07-31 19:37:49 +02:00
+++ 1.348/sql/sql_select.cc 2005-08-01 08:31:12 +02:00
@@ -1762,7 +1762,7 @@
for (handlerton **pht= thd->transaction.stmt.ht; *pht; pht++)
{
const handlerton *ht= *pht;
- close_at_commit|= (ht->flags & HTON_CLOSE_CURSORS_AT_COMMIT);
+ close_at_commit|= test(ht->flags & HTON_CLOSE_CURSORS_AT_COMMIT);
if (ht->create_cursor_read_view)
{
info->ht= ht;
@@ -2758,11 +2758,9 @@
We use null_rejecting in add_not_null_conds() to add
'othertbl.field IS NOT NULL' to tab->select_cond.
*/
- (*key_fields)->null_rejecting= (cond->functype() == Item_func::EQ_FUNC) &&
- ((*value)->type() == Item::FIELD_ITEM) &&
-
- (((Item_field*)*value)->field->maybe_null() ||
- ((Item_field *)*value)->field->table->maybe_null);
+ (*key_fields)->null_rejecting= ((cond->functype() == Item_func::EQ_FUNC) &&
+ ((*value)->type() == Item::FIELD_ITEM) &&
+ ((Item_field*)*value)->field->maybe_null());
(*key_fields)++;
}
@@ -8036,11 +8034,13 @@
bool table_cant_handle_bit_fields,
uint convert_blob_length)
{
- Item *org_item= item;
- if (item->real_item()->type() == Item::FIELD_ITEM)
+ if (type != Item::FIELD_ITEM &&
+ item->real_item()->type() == Item::FIELD_ITEM &&
+ (item->type() != Item::REF_ITEM ||
+ !((Item_ref *) item)->depended_from))
{
item= item->real_item();
- type= item->type();
+ type= Item::FIELD_ITEM;
}
switch (type) {
case Item::SUM_FUNC_ITEM:
@@ -8054,23 +8054,18 @@
case Item::FIELD_ITEM:
case Item::DEFAULT_VALUE_ITEM:
{
- if (org_item->type() != Item::REF_ITEM ||
- !((Item_ref *)org_item)->depended_from)
- {
- Item_field *field= (Item_field*) item;
- if (table_cant_handle_bit_fields &&
- field->field->type() == FIELD_TYPE_BIT)
- return create_tmp_field_from_item(thd, item, table, copy_func,
- modify_item, convert_blob_length);
- return create_tmp_field_from_field(thd, (*from_field= field->field),
- item->name, table,
- modify_item ? (Item_field*) item :
- NULL,
- convert_blob_length);
- }
- else
- item= org_item;
+ Item_field *field= (Item_field*) item;
+ if (table_cant_handle_bit_fields &&
+ field->field->type() == FIELD_TYPE_BIT)
+ return create_tmp_field_from_item(thd, item, table, copy_func,
+ modify_item, convert_blob_length);
+ return create_tmp_field_from_field(thd, (*from_field= field->field),
+ item->name, table,
+ modify_item ? (Item_field*) item :
+ NULL,
+ convert_blob_length);
}
+ /* Fall through */
case Item::FUNC_ITEM:
case Item::COND_ITEM:
case Item::FIELD_AVG_ITEM:
@@ -10919,13 +10914,13 @@
usable_keys.set_all();
for (ORDER *tmp_order=order; tmp_order ; tmp_order=tmp_order->next)
{
- if ((*tmp_order->item)->real_item()->type() != Item::FIELD_ITEM)
+ Item *item= (*tmp_order->item)->real_item();
+ if (item->type() != Item::FIELD_ITEM)
{
usable_keys.clear_all();
DBUG_RETURN(0);
}
- usable_keys.intersect(((Item_field*) (*tmp_order->item)->real_item())->
- field->part_of_sortkey);
+ usable_keys.intersect(((Item_field*) item)->field->part_of_sortkey);
if (usable_keys.is_clear_all())
DBUG_RETURN(0); // No usable keys
}
| Thread |
|---|
| • bk commit into 5.0 tree (schwenke:1.1917) | axel | 1 Aug |