client/mysql.cc:
Auto merged
libmysql/libmysql.c:
Auto merged
sql/ha_ndbcluster.cc:
Auto merged
sql/item.cc:
Auto merged
sql/item.h:
Auto merged
sql/item_func.cc:
Auto merged
sql/item_subselect.cc:
Auto merged
sql/item_sum.cc:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/opt_range.cc:
Auto merged
sql/sql_base.cc:
Auto merged
sql/sql_bitmap.h:
Auto merged
sql/sql_class.h:
Auto merged
sql/sql_insert.cc:
Auto merged
sql/sql_parse.cc:
Auto merged
sql/sql_select.cc:
Auto merged
Simple optimization for 2 argument usage to function of variable arguments
Fix stack overrun when using 1+1+1+1+1+1+1+....
Update crash-me results for 5.0
Don't call post_open if pre_open() fails (optimization)
sql-bench/limits/mysql-4.1.cfg:
Rename: sql-bench/limits/mysql.cfg -> sql-bench/limits/mysql-4.1.cfg
libmysql/libmysql.c:
More portable define
mysql-test/mysql-test-run.sh:
Write also InnoDB warnings to warnings.log
mysql-test/t/type_newdecimal.test:
Don't get errors if innodb is not defined
mysys/my_alloc.c:
Cleanup comments
mysys/thr_lock.c:
Cleanup comments
sql/item.h:
Remove not needed initializer
sql/item_func.cc:
Simple optimization for 2 argument usage to function of variable arguments
sql/mysql_priv.h:
We use more stackspace with the introduction of int_op() etc.
This change ensures we don't run out of stack when doing 1+1+1+1...
(Tested on x86, 32 bit)
sql/sp_head.cc:
Don't call post_open if pre_open() fails
sql/sp_rcontext.cc:
More comments
Change so that post_open() doesn't have to be called if pre_open() fails
sql/sql_parse.cc:
Fold long lines
sql/sql_select.cc:
Simple reorganization to reduce number of if's
Ensure that table_map is updated for where clause (fixed warning from valgrind)
Changed name of function my_correct_default_file to
modify_defaults_file. Improved function and fixed some
bugs in it.
include/my_sys.h:
Changed function name.
include/mysql_com.h:
New function, modify_defaults_file()
libmysql/Makefile.shared:
New file, default_modify.lo
libmysql/libmysql.def:
New function, modify_defaults_file() and fixed version number.
libmysqld/libmysqld.def:
New function, modify_defaults_file()
mysys/Makefile.am:
New file, default_modify.c
mysys/default.c:
Removed function from default.c. New, corresponding one is in default_modify.c,
name is modify_defaults_file.
server-tools/instance-manager/commands.cc:
Changed function name.
sql/mysqld.cc:
Fixed typo.
- check on the client the unsupported feature and return
an error message if it's been requested.
Additionally added API support for STMT_ATTR_PREFETCH_ROWS.
Post-review fixes.
include/errmsg.h:
Add a new error code for "Not implemented" client-side error message.
include/mysql.h:
Add a statement attribute STMT_ATTR_PREFETCH_ROWS - unsigned long
number of rows to fetch per one COM_FETCH command, used when there
is a read-only cursor.
Note, that we don't break compatibility by adding this new member
because MYSQL_STMT is always allocated inside the client library by
mysql_stmt_init.
libmysql/errmsg.c:
Text for the error message CR_NOT_IMPLEMENTED
libmysql/libmysql.c:
Implement support for STMT_ATTR_PREFETCH_ROWS
Return an error message on attempt to set an attribute of a prepared
statement which is not implemented yet. We probably should be doing
it in the server: currently the server just ignores unknown attributes.
tests/mysql_client_test.c:
A test case for Bug#9643 "CURSOR_TYPE_SCROLLABLE dos not work"
- check that an error message is returned for CURSOR_TYPE_SCROLLABLE.
Additionally, check setting of STMT_ATTR_PREFETCH_ROWS.
include/my_sys.h:
added prototype for the defaults correction function
libmysql/Makefile.shared:
my_chsize added to libmysql to let my_correct_defaults_file be used from libmysql
mysys/default.c:
New defaults function added we use it to correct defaults file. Currently the function doesn't lock defaults
file. This is because of the linking and backwards-compatibility issues. This needs to be fixed later.
mysys/my_chsize.c:
comment added
server-tools/instance-manager/buffer.cc:
cleanup
server-tools/instance-manager/commands.cc:
refactoring: removed do_command method from most of the classes
server-tools/instance-manager/commands.h:
cleanup
server-tools/instance-manager/guardian.cc:
cleanup
server-tools/instance-manager/instance.cc:
cleanup
server-tools/instance-manager/instance_map.cc:
cleanup
server-tools/instance-manager/instance_options.cc:
cleanup
server-tools/instance-manager/instance_options.h:
cleanup
server-tools/instance-manager/listener.cc:
cleanup
server-tools/instance-manager/log.cc:
cleanup
server-tools/instance-manager/manager.cc:
cleanup
server-tools/instance-manager/messages.cc:
new errors added
server-tools/instance-manager/mysql_connection.cc:
cleanup
server-tools/instance-manager/mysql_manager_error.h:
new error codes added
server-tools/instance-manager/mysqlmanager.cc:
clenup
server-tools/instance-manager/options.cc:
cleanup
server-tools/instance-manager/parse.cc:
removed unused function
server-tools/instance-manager/parse.h:
removed prototype
server-tools/instance-manager/protocol.cc:
cleanup
server-tools/instance-manager/protocol.h:
added enum to be used in protocol.cc instead of the constants
BitKeeper/etc/logging_ok:
auto-union
BitKeeper/deleted/.del-errmsg.txt~11edc4db89248c16:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~184eb1f09242dc72:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~2cdeb8d6f80eba72:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~4617575065d612b9:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~587903f9311db2d1:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~606dfaeb9e81aa4e:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~6bbd9eac7f0e6b89:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~7397c423c52c6d2c:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~898865062c970766:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~8ed1999cbd481dc4:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~94a93cc742fca24d:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~9dab24f7fb11b1e1:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~b44a85a177954da0:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~b6181e29d8282b06:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~ba132dc9bc936c8a:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~e2609fdf7870795:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~e3183b99fbba0a9c:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~eeb2c47537ed9c23:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~ef28b592c7591b7:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~ef53c33ac0ff8a84:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~f19bfd5d4c918964:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~f96b7055cac394e:
Auto merged
libmysql/libmysql.c:
Auto merged
myisam/mi_key.c:
Auto merged
mysql-test/r/alter_table.result:
Auto merged
mysql-test/r/auto_increment.result:
Auto merged
mysql-test/r/innodb.result:
Auto merged
mysql-test/r/select.result:
Auto merged
mysql-test/t/alter_table.test:
Auto merged
mysql-test/t/innodb.test:
Auto merged
mysql-test/t/select.test:
Auto merged
sql/handler.h:
Auto merged
sql/item_func.cc:
Auto merged
sql/sql_yacc.yy:
Auto merged
mysql-test/r/insert_update.result:
Auto merged
strings/ctype-ucs2.c:
Auto merged
sql/sql_table.cc:
merge
sql/unireg.cc:
merge
BitKeeper/deleted/.del-outfile2.result~fb702ee2518d8e6d:
Delete: mysql-test/r/outfile2.result
libmysql/libmysql.c:
Fix indentation for new function mysql_set_character_set()
mysql-test/r/alter_table.result:
Fix test to be in same order as in 4.0
mysql-test/r/innodb.result:
After merge fix
mysql-test/r/insert_update.result:
Add extra test for insert into ... on duplicate key upate
mysql-test/r/outfile.result:
After merge fix
mysql-test/t/alter_table.test:
Fix test to be in same order as in 4.0
mysql-test/t/insert_update.test:
Add extra test for insert into ... on duplicate key upate
mysql-test/t/outfile.test:
After merge fix
sql/item_func.cc:
After merge fix
sql/sql_table.cc:
After merge fix
configure.in:
Auto merged
include/mysql.h:
Auto merged
innobase/row/row0mysql.c:
Auto merged
BitKeeper/deleted/.del-ctype-cp932.c:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~4617575065d612b9:
Auto merged
BitKeeper/deleted/.del-errmsg.txt~ffe4a0c9e3206150:
Auto merged
libmysql/libmysql.c:
Auto merged
libmysqld/Makefile.am:
Auto merged
mysql-test/r/ctype_ucs.result:
Auto merged
mysql-test/t/ctype_ucs.test:
Auto merged
mysql-test/t/ps_grant.test:
Auto merged
sql/ha_blackhole.cc:
Auto merged
strings/ctype-big5.c:
Auto merged
strings/ctype-ucs2.c:
Auto merged
as a work around for #8317 and #9637
This function sends SET NAMES command and changes mysql->charset
so mysql_real_escape_string will work as expected.
libmysql/libmysql.def:
added new function mysql_set_character_set
(crash on attempt to re-execute a statement with an open cursor) +
post-review fixes.
include/errmsg.h:
Add a special error message when we attempt to mysql_stmt_fetch
from a statement which has no result set.
libmysql/errmsg.c:
Error message text for CR_NO_RESULT_SET
libmysql/libmysql.c:
Move the code which frees result sets on client and closes the cursor
on server, resets long data state on client and server.
This makes one function out of two (mysql_stmt_reset and
mysql_stmt_free_result), thus aggregating all related reset work
in one place.
sql-common/client.c:
Fix one place where we flushed the pending result set of a statement,
but didn't set unbuffered_fetch_cancelled flag.
sql/share/errmsg.txt:
Fix format of ER_UNKNOWN_STMT_HANDLER error message (needs to
be fixed separately in 4.1). Add two new error messages
for the case when we fetch from when there is no cursor
and for the case when we attempt to execute a statement while there is
a cursor.
sql/sql_prepare.cc:
Return error when we fetch while there is no open cursor and
when we call execute while there is a pending cursor.
Fix mysql_stmt_reset to close the open cursor if there is any.
sql/sql_select.cc:
free_items and free_root moved to Cursor::close().
sql/sql_select.h:
A comment added.
tests/mysql_client_test.c:
A test case for Bug#9478, test the case of mysql_stmt_reset
called for client-side cached result set and for the case with open cursor.
All strcpy replaced with strmov (review request).
BitKeeper/etc/logging_ok:
auto-union
libmysql/Makefile.shared:
Auto merged
mysql-test/r/rpl_deadlock.result:
Auto merged
mysql-test/t/rpl_deadlock.test:
Auto merged
sql/mysqld.cc:
Auto merged
sql/structs.h:
Auto merged
sql/slave.cc:
merge
sql/slave.h:
merge
sql/sql_show.cc:
merge
and Bug#9159 "Server crash during mysql_stmt_close".
The patch adds support for single-row result sets in cursors.
libmysql/libmysql.c:
If we wanted a cursor, and the server wasn't able to create one,
buffer all rows on client. Currently this is possible only for
single row result sets and some SHOW commands.
sql/sql_prepare.cc:
Properly free resources if there was a request to open a cursor which
wasn't fullfilled.
Give error on attempt to open a cursor for a statement not returning
a result set.
sql/sql_select.h:
Initialize Item_arena of Cursor object. A case when a cursor object
is created but not used is possible with single-row result sets.
tests/mysql_client_test.c:
Test cases for Bug#8880 and Bug#9159
s/sleep/safe_sleep (thread safe); sleep 0/1/2/3/4/5/5/5 (get slave less late);
no message on error log (deadlock is too common sometimes), a global counter
instead (SHOW STATUS LIKE 'slave_retried_transactions').
Plus a fix for libmysql/Makefile.shared
libmysql/Makefile.shared:
When we "make clean" in libmysql/ we remove the symlinks there, so we
need to mark that they have to be recreated later: this is done by removing
../linked_libmysql_sources. If we don't do this, 'make' will fail after 'cd libmysql;make clean'.
This Makefile.shared is used by libmysql_r too.
No reason to remove linked_client_sources as we don't remove the links in client/.
mysql-test/r/rpl_deadlock.result:
result fix
mysql-test/t/rpl_deadlock.test:
small test addition
sql/mysqld.cc:
if active_mi could not be alloced, die. New SHOW STATUS LIKE "slave_retried_transactions".
sql/slave.cc:
If slave retries automatically a transaction, no message on error log
(too common situation); sleep 0 secs at first retry, then 1, 2, 3, 4,
5, 5, 5... Sleeping 0 is to get the least possible late, as deadlocks
are usually resolved at first try. New global counter rli->retried_trans
(for SHOW STATUS: total number of times the slave had to retry
any transaction). safe_sleep() is thread-safe, sleep() was not.
I change the rli->trans_retries counter to go from 0 to max instead
of the other way (better for new sleep()).
sql/slave.h:
new global counter rli->retried_trans
sql/sql_show.cc:
SHOW STATUS LIKE "slave_retried_transactions"; needs replication mutexes.
Can't be a simple SHOW_LONG, because active_mi is unset (not alloced yet)
when the static global status_vars is created (active_mi is set
in init_slave()).
sql/structs.h:
new SHOW_SLAVE_RETRIED_TRANS
BitKeeper/etc/logging_ok:
Logging to logging@openlogging.org accepted
into serg.mylan:/usr/home/serg/Abk/mysql-5.0
libmysql/libmysql.c:
Auto merged
sql/field.cc:
Auto merged
sql/handler.cc:
Auto merged
sql/item.cc:
Auto merged
sql/item_cmpfunc.cc:
Auto merged
sql/mysql_priv.h:
Auto merged
Windows to call CreateFileMapping() with correct arguments, and
propogating the introduction of query_id_t to everywhere query ids are
passed around. (Bug #8826)
libmysql/libmysql.c:
Make implicit cast explicit
myisam/mi_open.c:
Make cast of value to smaller data size explicit
myisam/mi_packrec.c:
Cast file size (my_off_t) to size_t for mmap
mysys/my_mmap.c:
Fix Windows version of my_mmap() to use the right parameters
for call to CreateFileMapping()
sql/field.cc:
Use temporary value of correct type
sql/field.h:
Use query_id_t for query_id value
sql/ha_berkeley.cc:
Fix flag check
sql/ha_innodb.h:
Use query_id_t for query_id value
sql/handler.cc:
Explain opt_using_transactions calculation, and add cast
sql/handler.h:
Fix forward declaration of COND
sql/item.cc:
Fix val_bool() tests of val_int() to avoid implicit cast
sql/item_cmpfunc.cc:
Fix typo in switch label
sql/item_func.cc:
Make implicit cast explicit
sql/item_strfunc.cc:
Now that query_id is a query_id_t, need to cast it to a ulong here
sql/item_subselect.cc:
Fix test of value
sql/log.cc:
Cast my_off_t used for file size to size_t for memory allocation
Also cast my_off_t when using it to calculate the number of pages for TC log
Cast total_ha_2pc to uchar when saving it
sql/mysql_priv.h:
Move up query_id definition so it can be used more widely
sql/opt_range.cc:
Add unused delete operator to prevent compiler warning
sql/set_var.cc:
Cast value for max_user_connections
sql/sql_cache.cc:
Remove unused label
sql/sql_class.h:
Fix query id values to be of type query_id_t
sql/sql_db.cc:
Move variable only used inside #ifdef within the #ifdef
sql/sql_help.cc:
Remove unused label
sql/sql_insert.cc:
Use query_id_t for query id values
sql/sql_lex.h:
Add unused delete operator to prevent compiler warning
sql/sql_select.cc:
Remove unused variable
Make cast of value explicit
sql/sql_select.h:
Use query_id_t for query id values
sql/sql_table.cc:
Make comparison to function pointer explicit
sql/sql_update.cc:
Use query_id_t for query id values
sql/table.h:
Use query_id_t for query id values
strings/ctype-simple.c:
Add cast of long value to (char) in expression
strings/ctype-ucs2.c:
Add cast of long value to (char) in expression
strings/ctype-utf8.c:
Make cast to smaller size explicit
don't call escape_string_for_mysql() unnecesary
don't overwrite local buffer
escape_string_for_mysql():
take a length of the destination buffer as an argument
include/my_sys.h:
prototype changed
libmysql/libmysql.c:
prototype changed
mysys/charset.c:
escape_string_for_mysql():
take a length of the destination buffer as an argument
sql/field.cc:
Field::quote_data():
don't call escape_string_for_mysql() unnecesary
don't overwrite local buffer
sql/item.cc:
prototype changed
sql/sql_prepare.cc:
prototype changed
This is the first changeset of suggested changes recommended in Kostja's
review of my patch, 1.1846, which includes only functionality changes.
Style changes/Documentation patch to follow.
include/mysql.h:
removed declaration of cli_fetch_lengths per Kostja's suggestion
libmysql/libmysql.c:
moved mysql_fetch_lengths to client.c (for server to access) per Kostja's
suggestion
sql-common/client.c:
added back 'static' to function definition, added mysql_fetch_lengths
sql/ha_federated.cc:
changed to use defines as opposed to hardcoded values
sql/ha_federated.h:
took out duplicate table_flag, fixed a resolve mistake
reset mysql->net.last_error": the solution is to clear
MYSQL->net error before performing COM_CLOSE: if the call
succeeds, the connection is usable for other statements.
More comprehensive fix is to clear MYSQL->net for all
recoverable errors at the time they happen, it will be
implemented in 5.0 as it introduces incompatibility in behavior.
libmysql/libmysql.c:
A simple fix for Bug#7990 "mysql_stmt_close doesn't reset
mysql->net.last_error"
tests/mysql_client_test.c:
A test case for Bug#7990 " mysql_stmt_close doesn't reset
mysql->net.last_error"
libmysql/libmysql.c:
Fix for bug#8330 "mysql_stmt_execute crashes": we need to bail out
from mysql_stmt_execute if mysql->net is occupied with a result set of
another statement. Otherwise on the next attempt to use net we get
a crash, as it's freed in case of error.
tests/mysql_client_test.c:
A test case for Bug#8330 "mysql_stmt_execute craches" (libmysql)