Commit graph

372 commits

Author SHA1 Message Date
unknown
33dde6ebfa Patch for bug 28386 enabled table logging for all tests in
mysql_client_test causing a severe slowdown and increase
in memory usage, especially for test cases with long queries.

The solution is to enable the general log only in tests that
actually need the general log and disable it during the
execution of all other tests.


tests/mysql_client_test.c:
  Selectively enable and disable the general log.
2008-03-24 22:39:48 -03:00
unknown
66ca07650f Merge quad.opbmk:/mnt/raid/alik/MySQL/devel/5.0-rt
into  quad.opbmk:/mnt/raid/alik/MySQL/devel/5.1-rt-merged


libmysql/libmysql.c:
  Auto merged
sql-common/client.c:
  Auto merged
tests/mysql_client_test.c:
  Manually merged.
2008-03-18 14:13:33 +03:00
unknown
f77686df0d Merge quad.opbmk:/mnt/raid/alik/MySQL/devel/5.0
into  quad.opbmk:/mnt/raid/alik/MySQL/devel/5.0-rt-merged


libmysql/libmysql.c:
  Auto merged
sql-common/client.c:
  Auto merged
tests/mysql_client_test.c:
  Manually merged.
2008-03-18 13:53:51 +03:00
unknown
07db330a55 Merge quad.opbmk:/mnt/raid/alik/MySQL/devel/5.1
into  quad.opbmk:/mnt/raid/alik/MySQL/devel/5.1-rt-merged


libmysql/libmysql.c:
  Auto merged
sql-common/client.c:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
2008-03-18 13:51:17 +03:00
unknown
809522598a Post-merge fixes for Bug 35103
libmysql/libmysql.c:
  Manual merge
sql/sql_class.cc:
  Don't send anything back to the client if disabled.
sql/sql_prepare.cc:
  Don't send any packet back for statement close.
tests/mysql_client_test.c:
  Manual merge
2008-03-17 16:39:09 -03:00
unknown
063b504772 Bug#35103 mysql_client_test::test_bug29948 causes sporadic failures
The problem was that the COM_STMT_SEND_LONG_DATA was sending a response
packet if the prepared statement wasn't found in the server (due to
reconnection). The commands COM_STMT_SEND_LONG_DATA and COM_STMT_CLOSE
should not send any packets, even error packets should not be sent since
they are not expected by the client API.

The solution is to clear generated during the execution of the aforementioned
commands and to skip resend of prepared statement commands. Another fix is
that if the connection breaks during the send of prepared statement command,
the command is not sent again since the prepared statement is no longer in the
server.


libmysql/libmysql.c:
  The mysql handle might be reset after a reconnection.
  Pass the now used stmt argument to cli_advanced_command.
sql-common/client.c:
  Don't resend command if the connection broke and it's a prepared
  statement command. If the session is broken, prepared statements
  on the server are gone, set the error accordanly.
sql/sql_prepare.cc:
  Clear any error set during the execution of the request
  command.
tests/mysql_client_test.c:
  Fix memory leak by freeing result associated with statement.
  Remove test case for Bug 29948 because it's not reliable in
  5.0 (fixed in 5.1) due to KILL queries sending two packets for
  a thread that kills itself.
2008-03-14 17:40:12 -03:00
unknown
f20fe94b55 Bug#35103 mysql_client_test::test_bug29948 causes sporadic failures
Disable test case for bug 29948, which is causing sporadically
failures in other tests inside mysql_client_test.


tests/mysql_client_test.c:
  Disable test case.
2008-03-13 12:14:14 +03:00
unknown
b0fda34b29 Merge quad.:/mnt/raid/alik/MySQL/devel/5.0-rt
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt


tests/mysql_client_test.c:
  Manually merged.
2008-03-12 15:52:38 +03:00
unknown
9fcf16a055 Merge kaamos.(none):/data/src/opt/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt


tests/mysql_client_test.c:
  Manual merge.
2008-03-12 13:29:50 +03:00
unknown
615db68d85 Re-enabled the test for mysql_insert_id() after merging from main. 2008-03-12 12:13:41 +03:00
unknown
d6df18dd33 Merge kaamos.(none):/data/src/mysql-5.1
into  kaamos.(none):/data/src/opt/mysql-5.1-opt


client/mysql.cc:
  Auto merged
client/mysqldump.c:
  Auto merged
configure.in:
  Auto merged
include/my_global.h:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
mysql-test/include/mix1.inc:
  Auto merged
mysql-test/r/create.result:
  Auto merged
mysql-test/r/func_str.result:
  Auto merged
mysql-test/r/innodb.result:
  Auto merged
mysql-test/r/innodb_mysql.result:
  Auto merged
mysql-test/r/select.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/t/create.test:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_plugin.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
storage/ndb/src/kernel/blocks/backup/Backup.hpp:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
mysql-test/r/func_time.result:
  Manual merge.
mysql-test/r/view.result:
  Manual merge.
mysql-test/t/view.test:
  Manual merge.
scripts/mysql_config.sh:
  Manual merge.
sql-common/client.c:
  Manual merge.
sql/sql_parse.cc:
  Manual merge.
2008-03-12 11:19:46 +03:00
unknown
09f8a4af63 Merge kaamos.(none):/data/src/mysql-5.0
into  kaamos.(none):/data/src/opt/mysql-5.0-opt


client/mysql.cc:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
mysql-test/r/view.result:
  Manual merge.
mysql-test/t/view.test:
  Manual merge.
scripts/mysql_config.sh:
  Manual merge.
2008-03-12 10:59:15 +03:00
unknown
92e0fbbe84 Merge kaamos.(none):/data/src/opt/bug34889/my50
into  kaamos.(none):/data/src/opt/bug34889/my51


sql/sql_insert.cc:
  Null merge.
tests/mysql_client_test.c:
  Manual merge.
2008-03-08 11:21:11 +03:00
unknown
aafb492d59 Bug#35103 mysql_client_test::test_bug29948 causes sporadic failures
Disable test case for bug 29948, which is causing sporadically
failures in other tests inside mysql_client_test.


tests/mysql_client_test.c:
  Disable test case.
2008-03-06 09:16:53 -03:00
unknown
0c1dd98ec8 Fix for bug #34889: mysql_client_test::test_mysql_insert_id test fails
sporadically

Under some circumstances, the mysql_insert_id() value after SELECT ...
INSERT could return a wrong value. This could happen when the last
SELECT ... INSERT did not involve an AUTO_INCREMENT column, but the
value of mysql_insert_id() was changed by some previous statements.

Fixed by checking the value of thd->insert_id_used in
select_insert::send_eof() and returning 0 for mysql_insert_id() if it
is not set.


sql/sql_insert.cc:
  Do not return thd->last_insert_id unconditionally in
  select_insert::send_eof(). First check if thd->insert_id_used is
  non-zero, and return 0 otherwise.
tests/mysql_client_test.c:
  Added a test case for bug #34889.
2008-03-05 16:02:33 +03:00
unknown
b3cc07838d Merge quad.:/mnt/raid/alik/MySQL/devel/5.0-rt
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-build


tests/mysql_client_test.c:
  Manually merged.
2008-02-27 22:58:42 +03:00
unknown
b43f8f695c Eliminate compilation warning. 2008-02-27 22:29:58 +03:00
unknown
e78d896c3f Bug#34889 mysql_client_test::test_mysql_insert_id test fails sporadically
Disable the test case.


tests/mysql_client_test.c:
  Disable test case.
2008-02-27 13:05:46 -03:00
unknown
336f2c7e51 Merge quad.:/mnt/raid/alik/MySQL/devel/5.1
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged


client/mysqltest.c:
  Auto merged
mysql-test/r/view.result:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_ndbcluster_binlog.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_connect.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
mysql-test/suite/rpl_ndb/t/disabled.def:
  Manually merged.
mysql-test/t/disabled.def:
  Manually merged.
2008-02-26 19:34:02 +03:00
unknown
2aa0927d9c Fix the remaining memory leaks (mysql_client_test).
tests/mysql_client_test.c:
  Fix the remaining memory leaks.
2008-02-26 18:07:11 +03:00
unknown
6b9db6d213 Valgrind errors in mysql_client_test.
tests/mysql_client_test.c:
  Fix a memory leak.
  Run the test for Bug#28386 only if logging to tables is enabled.
2008-02-26 17:25:21 +03:00
unknown
fd31753387 Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  mysql.com:/Users/davi/mysql/mysql-5.1-runtime


tests/mysql_client_test.c:
  Auto merged
2008-02-26 10:12:26 -03:00
unknown
1f3c170662 Merge dipika.(none):/opt/local/work/mysql-5.0-runtime
into  dipika.(none):/opt/local/work/mysql-5.1-runtime


tests/mysql_client_test.c:
  Manual merge.
2008-02-26 15:32:32 +03:00
unknown
24039016f0 Fix memory leaks (valgrind) 2008-02-26 15:27:46 +03:00
unknown
2967e4e104 Use an API instead of looking into stmt internals to fetch fields
(Test for Bug#32265)


tests/mysql_client_test.c:
  Use an API instead of looking into stmt internals to fetch fields.
2008-02-26 13:55:46 +03:00
unknown
b2e879cbe8 Bug#28386 the general log is incomplete
The problem is that the commands COM_STMT_CLOSE, COM_STMT_RESET,
COM_STMT_SEND_LONG_DATA weren't being logged to the general log.

The solution is to log the general log the aforementioned commands.


mysql-test/t/mysql_client_test-master.opt:
  Also log to table.
sql/sql_prepare.cc:
  Log COM_STMT_CLOSE, COM_STMT_RESET and COM_STMT_SEND_LONG_DATA.
tests/mysql_client_test.c:
  Add test case for Bug#28386
2008-02-25 07:48:02 -03:00
unknown
233143fd31 Fix for Bug#29605
--local-infile=0 checks can be bypassed by sending a FETCH LOCAL FILE response
  
Add a check for CLIENT_LOCAL_FILES before sending a local file.
Beware, that all binary distributions enable sending of local files and it's up
to the programs which use libmysql to disable it, if they don't use this functionality.
Otherwise they are not safe.


client/mysqltest.c:
  Enable LOAD DATA LOCAL INFILE for the test suite, like some rpl and ndb test.
sql-common/client.c:
  Check if the client has LOAD DATA LOCAL INFILE disabled and
  don't serve such requests from the server. This is not 100% proof,
  as if the client has this enabled, in all binary builds for BC,
  the check won't work and the client can be tricked into sending a
  local file.
tests/mysql_client_test.c:
  Switch on LOCAL INFILE in client test. If one day there
  is a test which uses it, then it will work out of the box.
2008-02-22 18:45:45 +01:00
unknown
88421ee503 Post-merge fixes for bugs 34587 and 32265.
mysql-test/r/view.result:
  Drop created view.
mysql-test/t/view.test:
  Update test result.
sql/sql_cursor.cc:
  Fix compilation failure.
tests/mysql_client_test.c:
  Manual merge.
2008-02-20 23:30:29 -02:00
unknown
96b4648b01 Merge buzz.(none):/home/davi/mysql-5.0-runtime
into  buzz.(none):/home/davi/mysql-5.1-runtime


sql/sql_cursor.cc:
  Auto merged
tests/mysql_client_test.c:
  SCCS merged
2008-02-20 23:18:40 -02:00
unknown
d34f8384b3 Post-merge fix to silence a compilation warning introduced
by patch for bug 32265 .


tests/mysql_client_test.c:
  Removed unused variable.
2008-02-20 22:11:06 -03:00
unknown
a399fefd56 Bug#32265 Server returns different metadata if prepared statement is used
Executing a prepared statement associated with a materialized
cursor yields to the client a metadata packet with wrong table
and database names. The problem was occurring because the server
was sending the the name of the temporary table used by the cursor
instead of the table name of the original table. The same problem
occurs when selecting from views, in which case the table name was
being sent and not the name of the view.
  
The solution is to fill the list item from the temporary table but
preserving the table and database names of the original fields. This
is achieved by tweaking the Select_materialize to accept a pointer to
the Materialized_cursor class which contains the item list to be filled.


sql/sql_cursor.cc:
  Fill the item list in the send_fields method and preserve
  the table and database name of the fields.
tests/mysql_client_test.c:
  Add test case for Bug#32265
2008-02-20 16:45:24 -03:00
unknown
85213f6235 Fix for server bug experienced in Maria (wrong "Truncated incorrect <var_name>
value" error even though the value was correct): a C function in my_getopt.c
was taking bool* in parameter and was called from C++ sql_plugin.cc,
but on some Mac OS X sizeof(bool) is 1 in C and 4 in C++, giving funny
mismatches. Fixed, all other occurences of bool in C are removed, future
ones are blocked by a "C-bool-catcher" in my_global.h (use my_bool).


client/mysqldump.c:
  my_bool for C
client/mysqltest.c:
  my_bool for C
extra/replace.c:
  my_bool for C
include/my_getopt.h:
  my_bool for C
include/my_global.h:
  Prevent people from using bool in C, it causes real bugs.
include/my_sys.h:
  my_bool for C
include/my_time.h:
  my_bool for C
include/thr_lock.h:
  my_bool for C
libmysql/libmysql.c:
  my_bool for C
mysys/charset.c:
  my_bool for C
mysys/my_getopt.c:
  my_bool for C
mysys/queues.c:
  my_bool for C
mysys/thr_lock.c:
  my_bool for C
regex/reginit.c:
  my_bool for C
sql/set_var.cc:
  C functions use my_bool so we must use my_bool too.
sql/sql_plugin.cc:
  C functions use my_bool so we must use my_bool too.
  This fixes a real observed bug of Maria, because on some Mac OS X,
  sizeof(bool) is 1 in C and 4 in C++, so the bool* does wrong.
  Removing useless line.
storage/heap/hp_update.c:
  my_bool for C
storage/myisam/mi_check.c:
  my_bool for C
storage/myisam/mi_dynrec.c:
  my_bool for C
storage/myisam/mi_search.c:
  my_bool for C
storage/myisam/mi_update.c:
  my_bool for C
storage/myisam/mi_write.c:
  my_bool for C
storage/myisam/myisamdef.h:
  my_bool for C
storage/myisam/myisamlog.c:
  my_bool for C
storage/myisam/myisampack.c:
  my_bool for C
tests/mysql_client_test.c:
  my_bool for C
unittest/mysys/bitmap-t.c:
  my_bool for C
vio/viosslfactories.c:
  my_bool for C
2008-02-18 23:29:39 +01:00
unknown
a114ede24a Bug#33699: The UPDATE statement allows NULL as new value on a NOT NULL
columns (default datatype value is assigned).

The mysql_update function has been modified to generate
an error when trying to set a NOT NULL field to NULL rather than a warning
in the set_field_to_null_with_conversions function.



mysql-test/extra/rpl_tests/rpl_extraMaster_Col.test:
  Updated test case (for bug#33699).
mysql-test/include/ps_modify.inc:
  Updated test case (for bug#33699).
mysql-test/r/auto_increment.result:
  Updated test case (for bug#33699).
mysql-test/r/null.result:
  Updated test case (for bug#33699).
mysql-test/r/ps_2myisam.result:
  Updated test case (for bug#33699).
mysql-test/r/ps_3innodb.result:
  Updated test case (for bug#33699).
mysql-test/r/ps_4heap.result:
  Updated test case (for bug#33699).
mysql-test/r/ps_5merge.result:
  Updated test case (for bug#33699).
mysql-test/r/warnings.result:
  Updated test case (for bug#33699).
mysql-test/suite/ndb/r/ps_7ndb.result:
  Updated test case (for bug#33699).
mysql-test/suite/rpl/r/rpl_extraColmaster_innodb.result:
  Updated test case (for bug#33699).
mysql-test/suite/rpl/r/rpl_extraColmaster_myisam.result:
  Updated test case (for bug#33699).
mysql-test/suite/rpl/t/rpl_err_ignoredtable.test:
  Updated test case (for bug#33699).
mysql-test/t/auto_increment.test:
  Updated test case (for bug#33699).
mysql-test/t/null.test:
  Updated test case (for bug#33699).
mysql-test/t/warnings.test:
  Updated test case (for bug#33699).
sql/sql_update.cc:
  Bug#33699: The mysql_update function has been modified to generate
  an error when trying to set a NOT NULL field to NULL rather than
  a warning in the set_field_to_null_with_conversions function.
tests/mysql_client_test.c:
  Updated test case (for bug#33699).
2008-01-11 05:06:08 +04:00
unknown
f7f96cd28d after merge fix 2007-12-13 16:43:38 +04:00
unknown
9a10c20ba9 Merge mysql.com:/home/gluh/MySQL/Merge/5.1
into  mysql.com:/home/gluh/MySQL/Merge/5.1-opt


BitKeeper/etc/ignore:
  auto-union
client/mysql.cc:
  Auto merged
client/mysqltest.c:
  Auto merged
include/mysql_com.h:
  Auto merged
libmysql/CMakeLists.txt:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
mysql-test/r/archive.result:
  Auto merged
mysql-test/r/create.result:
  Auto merged
mysql-test/r/delayed.result:
  Auto merged
mysql-test/r/func_misc.result:
  Auto merged
mysql-test/r/innodb.result:
  Auto merged
mysql-test/r/innodb_mysql.result:
  Auto merged
mysql-test/r/merge.result:
  Auto merged
mysql-test/r/ps.result:
  Auto merged
mysql-test/r/type_date.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_innodb_bug28430.result:
  Auto merged
mysql-test/t/create.test:
  Auto merged
mysql-test/t/func_misc.test:
  Auto merged
mysql-test/t/information_schema.test:
  Auto merged
mysql-test/t/merge.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/type_date.test:
  Auto merged
mysql-test/t/type_datetime.test:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
mysys/queues.c:
  Auto merged
sql/events.cc:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/ha_partition.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_partition.cc:
  Auto merged
sql/sql_plugin.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_string.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.cc:
  Auto merged
sql/table.h:
  Auto merged
storage/myisam/ha_myisam.cc:
  Auto merged
storage/myisam/mi_check.c:
  Auto merged
storage/myisam/mi_open.c:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
mysql-test/lib/mtr_report.pl:
  manual merge
mysql-test/r/myisam.result:
  manual merge
mysql-test/r/partition.result:
  manual merge
mysql-test/r/user_var.result:
  manual merge
mysql-test/t/myisam.test:
  manual merge
mysql-test/t/partition.test:
  manual merge
mysql-test/t/user_var.test:
  manual merge
sql/item.h:
  manual merge
sql/item_func.cc:
  manual merge
storage/myisammrg/ha_myisammrg.cc:
  manual merge
2007-12-13 15:56:04 +04:00
unknown
76a5b3b976 Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  mysql.com:/misc/mysql/31177/51-31177


tests/mysql_client_test.c:
  Auto merged
2007-12-10 08:20:33 +01:00
unknown
1ebb563422 Bug #31177: Server variables can't be set to their current values
fixes for SLES10


mysql-test/r/change_user.result:
  It's unsigned.
mysys/my_getopt.c:
  Failsafe no longer needed, we handle signedness correctly now.
sql/set_var.cc:
  ha_rows can be derived from all kinds of types, but
  they're all unsigned. Display it as such.
tests/mysql_client_test.c:
  cannot easily check this here due to types.
  check with Alik whether we need this on top
  of change_user.test.
2007-12-10 08:12:41 +01:00
unknown
54d5afd371 Merge bk@192.168.21.1:mysql-5.1-opt
into  mysql.com:/home/hf/work/26921/my51-26921


libmysqld/lib_sql.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
2007-12-07 10:10:02 +04:00
unknown
1dd429fd3e Merge mysql.com:/home/hf/work/26921/my50-26921
into  mysql.com:/home/hf/work/26921/my51-26921


libmysqld/lib_sql.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
2007-12-07 09:39:31 +04:00
unknown
0baec33ff3 Merge bk@192.168.21.1:mysql-5.0-opt
into  mysql.com:/home/hf/work/mrg/my50-mrg


tests/mysql_client_test.c:
  Auto merged
2007-12-01 13:12:31 +04:00
unknown
51f5ac6b29 Merge mysql.com:/home/hf/work/mrg/my50-mrg
into  mysql.com:/home/hf/work/mrg/my51-mrg


sql/mysqld.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
storage/federated/ha_federated.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
include/mysql_com.h:
  merging
libmysqld/lib_sql.cc:
  merging
mysql-test/r/federated.result:
  merging
mysql-test/t/federated.test:
  merging
storage/federated/ha_federated.h:
  mergin
2007-12-01 00:46:44 +04:00
unknown
07be2ef594 Merge polly.(none):/home/kaa/src/opt/bug9481/my50-bug9481
into  polly.(none):/home/kaa/src/opt/mysql-5.0-opt


sql/sql_class.h:
  Auto merged
sql/sql_insert.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
2007-11-30 18:45:35 +03:00
unknown
05fbb233d8 Bug #26921 Problem in mysql_insert_id() Embedded C API function.
client library only sets mysql->insert_id when query returned
no recordset. So the embedded library should behave the same way


libmysqld/lib_sql.cc:
  Bug #26921 Problem in mysql_insert_id() Embedded C API function.
  
  only set 'affected_rows' and 'insert_id' fields when query
  didn't return a recordset
tests/mysql_client_test.c:
  Bug #26921 Problem in mysql_insert_id() Embedded C API function.
  
  testcase added
2007-11-30 19:16:13 +04:00
unknown
1d062682f5 Bug #32624 Error with multi queries in MySQL embedded server 5.1.22.
server status wasn't properly sent to the client after the error
by the embedded server. Wasn't noticed before as one usually stopped
retrieving results after he gets an error.


libmysqld/lib_sql.cc:
  Bug #32624 Error with multi queries in MySQL embedded server 5.1.22.
  
  server status transferred to the client after errors
sql/protocol.cc:
  Bug #32624 Error with multi queries in MySQL embedded server 5.1.22.
  
  set server status before net_send_error_packet() call as this
  function sends it to the client in the embedded server
tests/mysql_client_test.c:
  Bug #32624 Error with multi queries in MySQL embedded server 5.1.22.
  
  testcase added
2007-11-29 10:37:07 +04:00
unknown
1836b73600 5.0 version of the fix for bug #9481: mysql_insert_id() returns 0 after
insert ... select.

The 5.0 manual page for mysql_insert_id() does not mention anything
about INSERT ... SELECT, though its current behavior is incosistent
with what the manual says about the plain INSERT.

Fixed by changing the AUTO_INCREMENT and mysql_insert_id() handling
logic in INSERT ... SELECT to be consistent with the INSERT behavior,
the manual, and the changes in 5.1 introduced by WL3146:


- mysql_insert_id() now returns the first automatically generated
AUTO_INCREMENT value that was successfully inserted by INSERT ... SELECT

-  if an INSERT ... SELECT statement is executed, and no automatically
generated value is successfully inserted, mysql_insert_id() now returns
the ID of the last inserted row.


sql/sql_class.h:
  Replaced last_insert_id with autoinc_value_of_last_inserted_row to be
  consistent with 5.1 code.
sql/sql_insert.cc:
  Revised the AUTO_INCREMENT and mysql_insert_id() handling logic in
  INSERT ... SELECT to be consistent with INSERT behavior, the manual, and
  changes in 5.1 introduced by WL3146:
  
  - mysql_insert_id() now returns the first automatically generated
  AUTO_INCREMENT value that was successfully inserted;
  
  -  if an INSERT ... SELECT statement is executed, and no automatically
  generated value is successfully inserted, mysql_insert_id() now returns
  the ID of the last inserted row.
tests/mysql_client_test.c:
  Backported the test cases related to INSERT ... SELECT and
  mysql_insert_id() from WL3146 patch to 5.0.
2007-11-26 18:36:05 +03:00
unknown
10c1aa796a Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B32400-5.0-opt


tests/mysql_client_test.c:
  Auto merged
mysql-test/r/subselect.result:
  SCCS merged
mysql-test/t/subselect.test:
  SCCS merged
2007-11-23 15:30:16 +02:00
unknown
042a58e049 Merge magare.gmz:/home/kgeorge/mysql/work/B32400-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/work/B32400-5.1-opt


BitKeeper/deleted/.del-ps_6bdb.result:
  Auto merged
mysql-test/r/ps_2myisam.result:
  Auto merged
mysql-test/r/ps_3innodb.result:
  Auto merged
mysql-test/r/ps_4heap.result:
  Auto merged
mysql-test/r/ps_5merge.result:
  Auto merged
mysql-test/suite/ndb/r/ps_7ndb.result:
  Auto merged
sql/item.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
mysql-test/t/subselect.test:
  merge of bug 32400 to 5.1-opt
2007-11-23 14:41:47 +02:00
unknown
bac4f3e6ee Merge polly.(none):/home/kaa/src/opt/bug32221/my51-bug31445
into  polly.(none):/home/kaa/src/opt/mysql-5.1-opt


tests/mysql_client_test.c:
  Auto merged
2007-11-22 14:56:01 +03:00
unknown
10e1f245c4 Merge polly.(none):/home/kaa/src/opt/bug32221/my50-bug31445
into  polly.(none):/home/kaa/src/opt/mysql-5.0-opt


tests/mysql_client_test.c:
  Auto merged
2007-11-22 14:53:41 +03:00
unknown
0515b14020 Merge polly.(none):/home/kaa/src/opt/bug32221/my50-bug31445
into  polly.(none):/home/kaa/src/opt/bug32221/my51-bug31445


BitKeeper/deleted/.del-myTest.dsp~4a8c480769193952:
  Auto merged
BitKeeper/deleted/.del-mytest.c~9a99338689e5de8:
  Auto merged
BitKeeper/deleted/.del-mytest.dsw~2324698861155335:
  Auto merged
libmysql/Makefile.am:
  Auto merged
tests/bug25714.c:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
BitKeeper/deleted/.del-copy_mysql_files.bat~f6878eeb80173de9:
  Auto merged
BitKeeper/deleted/.del-mytest_1.c:
  Merge rename: BitKeeper/deleted/.del-mytest.c -> BitKeeper/deleted/.del-mytest_1.c
BitKeeper/deleted/.del-myTest-package.dsp~ec9faf3287cbe2b9:
  Auto merged
BitKeeper/deleted/.del-myTest-package_ia64.dsp~e423b69f2c624850:
  Auto merged
BitKeeper/deleted/.del-myTest.vcproj~dba5adc4fad3c06:
  Auto merged
BitKeeper/deleted/.del-myTest_ia64.dsp~b17572b217d092e6:
  Auto merged
libmysql/CMakeLists.txt:
  Manual merge.
2007-11-22 14:39:07 +03:00