1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Fix for UNION and LEFT JOIN (Bug #386)

Fixed wrong logging of Access denied error (Bug #398)


include/my_global.h:
  Fix for QNX
mysql-test/r/union.result:
  new test case
mysql-test/t/union.test:
  Test of bug in union and left join
mysys/my_seek.c:
  Safety fix to find out when pos gets a wrong value
sql/field.h:
  Fix for UNION and LEFT JOIN
sql/mysql_priv.h:
  Fix for UNION and LEFT JOIN
sql/sql_base.cc:
  Fix for UNION and LEFT JOIN
sql/sql_insert.cc:
  Fix for UNION and LEFT JOIN
sql/sql_parse.cc:
  Fixed wrong logging of Access denied error
sql/sql_union.cc:
  Fix for UNION and LEFT JOIN
sql/sql_update.cc:
  Fix for UNION and LEFT JOIN
This commit is contained in:
unknown
2003-05-13 18:58:26 +03:00
parent 4ccf66df87
commit dc1e55f819
11 changed files with 150 additions and 21 deletions

View File

@ -2112,7 +2112,7 @@ int setup_conds(THD *thd,TABLE_LIST *tables,COND **conds)
******************************************************************************/
int
fill_record(List<Item> &fields,List<Item> &values)
fill_record(List<Item> &fields,List<Item> &values, bool ignore_errors)
{
List_iterator_fast<Item> f(fields),v(values);
Item *value;
@ -2122,7 +2122,7 @@ fill_record(List<Item> &fields,List<Item> &values)
while ((field=(Item_field*) f++))
{
value=v++;
if (value->save_in_field(field->field, 0))
if (value->save_in_field(field->field, 0) && !ignore_errors)
DBUG_RETURN(1);
}
DBUG_RETURN(0);
@ -2130,7 +2130,7 @@ fill_record(List<Item> &fields,List<Item> &values)
int
fill_record(Field **ptr,List<Item> &values)
fill_record(Field **ptr,List<Item> &values, bool ignore_errors)
{
List_iterator_fast<Item> v(values);
Item *value;
@ -2140,7 +2140,7 @@ fill_record(Field **ptr,List<Item> &values)
while ((field = *ptr++))
{
value=v++;
if (value->save_in_field(field, 0))
if (value->save_in_field(field, 0) && !ignore_errors)
DBUG_RETURN(1);
}
DBUG_RETURN(0);