If item->cached_table is set, find_field_in_tables() returns found field
even if it doesn't belong to current select. Because Item_field::fix_fields
doesn't expect such behaviour, reported bug occurs.
Item_field::fix_fields() was modifed to detect when find_field_in_tables()
can return field from outer select and process such fields accordingly.
In order to ease this code which was searching and processing outed fields was
moved into separate function called Item_field::fix_outer_field().
sql/item_subselect.h:
Fixed bug #15706: find_field_in_tables() returns field from outer select
Item_field::fix_outer_field() was marked as friend to Item_subselect class.
sql/item.h:
Fixed bug #15706: find_field_in_tables() returns field from outer select
fix_outer_field() function is added to the Item_field class.
sql/item.cc:
Fixed bug #15706: find_field_in_tables() returns field from outer select
Item_ref::fix_fields() and Item_field::fix_fields() were modifed to detect when
find_field_in_tables() can return field from outer select and process such
fields accordingly.
In order to ease this, code Item_field::fix_fields() which was searching and
processing outer fields was moved into separate function called
Item_field::fix_outer_field().
To the Item_field::fix_field() added a loop for finding context for found field.
mysql-test/t/disabled.def:
Fixed bug #15706: find_field_in_tables() returns field from outer select
Enable subselect test
into neptunus.(none):/home/msvensson/mysql/mysql-5.0
client/mysqltest.c:
Auto merged
mysql-test/r/mysqltest.result:
Auto merged
mysql-test/t/mysqltest.test:
Auto merged
The Item_func_if::fix_length_and_dec() function when calculating length of
result doesn't take into account unsigned_flag. But it is taken when
calculating length of temporary field. This result in creating field that
shorter than needed. Due to this, in the reported query 40.0 converted to 9.99.
The function Item_func_if::fix_length_and_dec() now adds 1 to the max_length if
the unsigned_flag isn't set.
sql/item_cmpfunc.cc:
Fixed bug#16272: IF function with decimal args can produce wrong result
The function Item_func_if::fix_length_and_dec() now adds 1 to the max_length if
the unsigned_flag isn't set.
mysql-test/r/func_if.result:
Added test case for bug#16272: IF function with decimal args can produce wrong result
mysql-test/t/func_if.test:
Added test case for bug#16272: IF function with decimal args can produce wrong result
Backporting character_set_filesystem from 5.0 to 5.1.
sql/mysqld.cc:
Backporting character_set_filesystem from 5.0 to 5.1.
sql/set_var.cc:
Backporting character_set_filesystem from 5.0 to 5.1.
sql/set_var.h:
Backporting character_set_filesystem from 5.0 to 5.1.
sql/sql_class.cc:
Backporting character_set_filesystem from 5.0 to 5.1.
sql/sql_class.h:
Backporting character_set_filesystem from 5.0 to 5.1.
sql/sql_yacc.yy:
Backporting character_set_filesystem from 5.0 to 5.1.
mysql-test/t/variables.test:
Backporting character_set_filesystem from 5.0 to 5.1.
mysql-test/r/variables.result:
Backporting character_set_filesystem from 5.0 to 5.1.
Bug #17257 ndb, update fails for inner joins if tables do not have Primary Key
change: the allocated area by setValue may not be around for later, store hidden key in special member variable instead
mysql-test/r/ndb_basic.result:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
mysql-test/t/ndb_basic.test:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
sql/ha_ndbcluster.cc:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
change: the allocated area by setValue may not be around for later, store hidden key in special member variable instead
sql/ha_ndbcluster.h:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
change: the allocated area by setValue may not be around for later, store hidden key in special member variable instead
- Evaluate all variables in the text before printing it to result file
client/mysqltest.c:
Update echo command to vvaluate all variables in the string before printing, allow
for variable names to be escaped using \
mysql-test/r/mysqltest.result:
Update results for echo
mysql-test/t/mysqltest.test:
Add more advanced tests for echo of strings with several variables
and/or text plus variables. Also test that variables can be escaped
mysql-test/r/im_life_cycle.result:
correct result
mysql-test/t/im_life_cycle.imtest:
check that wrong command is processed correctly
server-tools/instance-manager/Makefile.am:
always look for passwords in /etc/ on unixes
server-tools/instance-manager/commands.cc:
fix warning
server-tools/instance-manager/instance.cc:
fix monitoring capabilities, when no port was specified
for an instance
server-tools/instance-manager/instance_map.cc:
allow relative paths in --defaults-file option
server-tools/instance-manager/mysqlmanager.cc:
fix windows warning
server-tools/instance-manager/options.cc:
add vars to allow relative paths in --defaults-file option
server-tools/instance-manager/options.h:
add an option
server-tools/instance-manager/parse.cc:
check for get_text_id return value
server-tools/instance-manager/portability.h:
add _snprintf define, move platfrom-independent
ifdefs to priv.h
server-tools/instance-manager/priv.cc:
increase net timeout. it should be equal to mysqld's
server-tools/instance-manager/priv.h:
move platform-independent ifdefs here
internal charset to one associated with currently being handled query.
To note such a query can come from interactive client either.
There was a discussion within replication team and Monty who's suggestion won.
It avoids straightforward parsing of all `set' queries that could affect client side
character set.
According to the idea, mysql client does not parse `set' queries but rather cares of
`charset new_cs_name' command.
This command is generated by mysqlbinlog in form of exclaiming comment (Lars' suggestion)
so that enlightened clients like `mysql' knows what to do with it.
Interactive human can switch between many multi-byte charsets during the session
providing the command explicitly.
To note that setting new internal mysql's charset does not
trigger sending any `SET' sql statement to the server.
client/mysql.cc:
BUG#16217 revealed the problem of switching between charsets in mysql client.
Such switching is necessary in a case when being scanned query consists of
multi-byte chars and internal charset was initialized differently. mysql finds
`/' escape and misiterprete it
while in fact one could be a part of a multi-byte symbol like the bug page reported.
This patch extends mysql `charset' command, '\C' shortcut.
mysql-test/r/ctype_ucs_binlog.result:
comment line generated by mysqlbinlog for processing of logs with multi-byte chars.
mysql-test/r/mysql.result:
results are altered due to #16217
mysql-test/r/mysqlbinlog.result:
Results are altered due to #16217
mysql-test/r/mysqlbinlog2.result:
commeted command for mysql client due to multi-byte binlog
mysql-test/r/rpl_charset.result:
commented command for mysql due to multi-byte binlogs
mysql-test/r/rpl_timezone.result:
commented command for mysql client due to multi-byte binlogs
mysql-test/r/user_var-binlog.result:
commented command for mysql client due to multi-byte binlogs
mysql-test/t/mysql.test:
Main test for mysql client is extended to check `charset' command.
mysql-test/t/mysqlbinlog.test:
Checking how /*! \C cs_name */ are added to the output of mysqlbinlog.
The exclaiming comment is for further processing by mysql client.
The added part mimics the failure to recover tables from binlog - see BUG#16217.
sql/log_event.cc:
Sending into output instructions for mysql client to switch internally
to appropriate charset.
mysql client is supposed to be invoked with --default-character-set=
"to default character set of the server created the binlog".
fix for bug#8461
BUG 8461 - TRUNCATE returns incorrect result if 2nd argument is negative
Reason: Both TRUNCATE/ROUND converts INTEGERS to DOUBLE and back to INTEGERS
Changed the integer routine to work on integers only.
This bug affects 4.1, 5.0 and 5.1
Fixing in 4.1 will need to change the routine to handle different types individually.
5.0 did had different routines for different types already just the INTEGER routine was bad.
sql/item_func.cc:
fix for bug#8461
BUG 8461 - TRUNCATE returns incorrect result if 2nd argument is negative
Reason: TRUNCATE converts INTEGERS to DOUBLE and back to INTEGERS
Both ROUND and TRUNCATE are affected by this.
Changed the integer routine to work on integers only.
This bug affects 4.1 5,0 and 5
Fixing in 4.1 will need to change the routine to handle different types individually.
mysql-test/r/kill.result:
This result chenged because of the correspondent test change.
mysql-test/t/kill.test:
This test fixed for kill on Mac OS X (which do not send OK)
Bug #17158 load data infile of char values into table of char with no (PK) fails to load
Bug #17081 Doing "LOAD DATA INFILE" directly after delete can cause missing data
mysql-test/r/ndb_load.result:
New BitKeeper file ``mysql-test/r/ndb_load.result''
mysql-test/t/ndb_load.test:
New BitKeeper file ``mysql-test/t/ndb_load.test''
If check_quick_select returns non-empty range then the function cost_group_min_max
cannot return 0 as an estimate of the number of retrieved records.
Yet the function erroneously returned 0 as the estimate in some situations.
mysql-test/r/group_min_max.result:
Added a test case for bug #16203.
mysql-test/t/group_min_max.test:
Added a test case for bug #16203.
into mysql.com:/extern/mysql/work/bug16568/mysql-5.0
mysql-test/r/sp.result:
Auto merged
mysql-test/t/sp.test:
Auto merged
sql/sp_head.cc:
Auto merged
sql/sp_head.h:
Auto merged
sql/sql_parse.cc:
Auto merged
sql/sql_yacc.yy:
Auto merged