Commit graph

28503 commits

Author SHA1 Message Date
unknown
101e618f7f Bug#14013 mysql_stmt_store_result() bombs if a cursor is open
- Add code to 'mysql_stmt_store_result' to allow it to be called on 
   a prepared statement with open server side cursor.
 - Add tests to mysql_client_test that uses 'mysql_stmt_store_result'


client/mysqltest.c:
  Enable cursor protocol(remove the ifdef BUG14013_FIXED)
  When running in cursor mode, the warnings from execute needs 
  to be extracted after mysql_stmt_execute, put them in a dynamic string 
  for later use.
  Untabify some tabs.
libmysql/libmysql.c:
  Allow 'mysql_stmt_store_result' to be called on a statement with an open server side cursor.
  Detect that a server side cursor is open and send a "fetch" to ask for all rows to be sent to the client.
  Read all binary rows as normal store.
  Check that server said last row was sent after all binary rows has been sent.
tests/mysql_client_test.c:
  Update 'fetch_n' function to take parameter indicating if 'mysql_stmt_store_result' should be used on the statement.
  Call fetch_n with parameter set to use 'mysql_stmt_store_result'
2006-02-10 14:50:29 +01:00
unknown
db16cfc578 Use common function 'append_field' to output the value of one field to the result.
Fix for extra zero in exponent of double values on windows.


client/mysqltest.c:
  Write new function 'append_field' which takes care of appending one field to the dynamic string.
  Use function 'append_field' from both ps and normal execution
  Add hack to 'append_field' that removes the extra '0' in exponent for double values on Windows.
mysql-test/r/type_float.result:
  One zero too much was removed( I think )
mysql-test/t/insert.test:
  Remove the "replace_result" for extra zero in  exponent
mysql-test/t/type_float.test:
  Remove the "replace_result" for extra zero in  exponent
mysql-test/t/variables.test:
  Remove the "replace_result" for extra zero in  exponent
2006-02-01 11:36:32 +01:00
unknown
db5fe0fc97 extra/comp_err.c : Fix a merge error.
extra/comp_err.c:
  Fix a merge error (closing '}' was lost), correct formatting (tab -> blanks).
2006-01-16 17:23:39 +01:00
unknown
111cacfc7f Manual merge of the fix for bug#16106.
Currently failing tests (for me) in non-debug build:
blackhole fulltext fulltext_cache fulltext_left_join fulltext_multi


scripts/mysqld_multi.sh:
  Auto merged
extra/comp_err.c:
  Manual merge: From 4.1 to 5.0, the license line was moved to a different place.
2006-01-16 16:48:05 +01:00
unknown
6bbc50cd85 Merge svojtovich@bk-internal.mysql.com:/home/bk/mysql-5.0
into  april.(none):/home/svoj/devel/mysql/BUG13835/mysql-5.0
2006-01-13 21:30:05 +04:00
unknown
7f397ffd95 BUG#13835: max key length is 1000 bytes when trying to create a fulltext index
Allow fulltext index on VARCHAR columns longer than max key length.


mysql-test/r/fulltext.result:
  A test case for BUG#13835 added.
mysql-test/t/fulltext.test:
  A test case for BUG#13835 added.
sql/sql_table.cc:
  Allow fulltext index on VARCHAR columns longer than max key length.
2006-01-13 21:25:12 +04:00
unknown
ddab016fc4 Merge mysql.com:/M40/push-4.0 into mysql.com:/M41/merge-4.1
extra/comp_err.c:
  Auto merged
scripts/mysqld_multi.sh:
  Auto merged
2006-01-13 17:45:01 +01:00
unknown
36d7f7ecf8 Merge mysql.com:/M41/mysql-4.1 into mysql.com:/M41/merge-4.1 2006-01-13 17:26:16 +01:00
unknown
85f2158b95 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0
into moonbone.local:/work/15347-bug-5.0-mysql
2006-01-13 18:42:15 +03:00
unknown
de4a3552e1 extra/comp_err.c + scripts/mysqld_multi.sh :
Copyright string fixes (bug#16106)


extra/comp_err.c:
  Ensure that the license spelling is as expected by the "mysql_copyright" tool.
  (bug#16106)
scripts/mysqld_multi.sh:
  The "mysql_copyright" tool will not change non-C files, so do not mention the license.
  (bug#16106)
2006-01-13 16:25:20 +01:00
unknown
7eb0f577d8 Merge
sql/sql_select.cc:
  Auto merged
mysql-test/r/select.result:
  SCCS merged
mysql-test/t/select.test:
  SCCS merged
2006-01-13 16:27:38 +03:00
unknown
b5a72e4a0b Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/usr/home/bar/mysql-5.0
2006-01-13 17:21:38 +04:00
unknown
9009800088 Merge mysql.com:/usr/home/bar/mysql-4.1.b15377
into  mysql.com:/usr/home/bar/mysql-5.0


ndb/src/kernel/blocks/dblqh/DblqhMain.cpp:
  Auto merged
strings/ctype-euc_kr.c:
  Auto merged
strings/ctype-gb2312.c:
  Auto merged
2006-01-13 16:39:33 +04:00
unknown
4e195cbd52 Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/usr/home/bar/mysql-4.1.b15377
2006-01-13 16:21:44 +04:00
unknown
4e91470d29 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0
into moonbone.local:/work/15538-bug-5.0-mysql


mysql-test/r/select.result:
  Auto merged
mysql-test/t/select.test:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2006-01-13 14:30:20 +03:00
unknown
0bb6e33957 Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/usr/home/bar/mysql-4.1.b15377
2006-01-13 14:22:53 +04:00
unknown
ef58dc435b Merge mysql.com:/usr/home/bar/mysql-4.1
into  mysql.com:/usr/home/bar/mysql-4.1.b15377
2006-01-13 14:16:16 +04:00
unknown
a8a4a22974 Merge
sql/item_cmpfunc.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
mysql-test/r/select.result:
  SCCS merged
mysql-test/t/select.test:
  SCCS merged
2006-01-13 12:13:50 +03:00
unknown
8a59fbc724 Merge perch.ndb.mysql.com:/home/jonas/src/41-work
into  perch.ndb.mysql.com:/home/jonas/src/mysql-4.1


ndb/src/kernel/blocks/dblqh/DblqhMain.cpp:
  Auto merged
2006-01-13 09:29:24 +01:00
unknown
891202f7d1 Merge perch.ndb.mysql.com:/home/jonas/src/50-work
into  perch.ndb.mysql.com:/home/jonas/src/mysql-5.0
2006-01-13 07:41:49 +01:00
unknown
b9e1c443b8 bug#15619 - ndb_autodiscover sometimes fails
ndb/src/mgmsrv/MgmtSrvr.cpp:
  Make sure that node allocating id is allowed to transporter connect
2006-01-13 07:40:15 +01:00
unknown
c43a7e2e87 Merge joreland@bk-internal.mysql.com:/home/bk/mysql-5.0
into  perch.ndb.mysql.com:/home/jonas/src/mysql-5.0
2006-01-13 07:31:35 +01:00
unknown
3bf3bb2008 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/dlenev/src/mysql-5.0-bg12198-2


mysql-test/r/sp.result:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
sql/sp_head.cc:
  Auto merged
2006-01-13 01:56:57 +03:00
unknown
c12a3dfefd Fix for bug #12198 "Temporary table aliasing does not work inside stored
functions".

We should ignore alias when we check if table was already marked as temporary
when we calculate set of tables to be prelocked. Otherwise we will erroneously
treat tables which are used in same routine and have same name but different
alias as non-temporary.


mysql-test/r/sp.result:
  Added test for bug #12198 "Temporary table aliasing does not work inside stored
  functions" and other tests which cover handling of temporary tables in prelocked
  mode.
mysql-test/t/sp.test:
  Added test for bug #12198 "Temporary table aliasing does not work inside stored
  functions" and other tests which cover handling of temporary tables in prelocked
  mode.
sql/sp_head.cc:
  sp_head::merge_table_list():
    We should ignore alias when we check if table was already marked as temporary
    when we calculate set of tables to be prelocked. Otherwise we will erroneously
    treat tables which are used in same routine and have same name but different
    alias as non-temporary.
2006-01-13 01:51:56 +03:00
unknown
0f4962c338 Fixed a bug in merge. 2006-01-12 20:49:47 +02:00
unknown
5c28e9c8d0 Fix for Netware build. 2006-01-12 20:31:00 +02:00
unknown
a48380cd9a Merge ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-4.1
into  ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-5.0


client/mysqlimport.c:
  Auto merged
include/config-netware.h:
  Auto merged
innobase/os/os0thread.c:
  Auto merged
netware/mysqld_safe.c:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/mysqld.cc:
  Merged from 4.1.
sql/sql_base.cc:
  Merged from 4.1.
sql/sql_handler.cc:
  Merged from 4.1.
sql/sql_select.cc:
  Merged from 4.1.
2006-01-12 20:28:23 +02:00
unknown
26252fa28b Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0
2006-01-12 18:25:51 +01:00
unknown
9e49c77ce6 Merge neptunus.(none):/home/msvensson/mysql/wl2930_fixup/my50-wl2930_fixup
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0
2006-01-12 18:23:44 +01:00
unknown
7b77b4c7bb Use "test ! -s" to check that file does not exist 2006-01-12 18:19:57 +01:00
unknown
1665d23707 Merge ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-4.0
into  ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-4.1


include/config-netware.h:
  Auto merged
innobase/os/os0thread.c:
  Auto merged
netware/mysqld_safe.c:
  Merge from 4.0 to 4.1
sql/mysqld.cc:
  Merge from 4.0 to 4.1
2006-01-12 17:47:58 +02:00
unknown
2946f9a64f NetWare specific change to increase thread stack size.
Changes to Netware specific mysqld_safe.c


include/config-netware.h:
  NetWare specific change to increase thread stack size.
innobase/os/os0thread.c:
  NetWare specific change to increase thread stack size.
netware/mysqld_safe.c:
  NetWare specific change to make multiple mysqld_safe instances
  work when called through a NCF file.
sql/mysqld.cc:
  NetWare specific change to increase thread stack size.
2006-01-12 15:10:12 +02:00
unknown
0fa2fdb9be Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/home/my/mysql-4.1
2006-01-12 14:40:39 +02:00
unknown
35d46cee7c Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/usr/home/bar/mysql-5.0
2006-01-12 16:07:06 +04:00
unknown
46fdcba4f1 sql_show.cc:
after-merge fix for
  bug#15581 COALESCE function truncates mutli-byte TINYTEXT values


sql/sql_show.cc:
  after-merge fix for bug#15581 COALESCE function truncates mutli-byte TINYTEXT values
  ,
2006-01-12 16:05:46 +04:00
unknown
cd1f75e9cb ctype_utf8.result:
After merge fix:
  fixing order of results.


mysql-test/r/ctype_utf8.result:
  After merge fix:
  fixing order of results.
2006-01-12 13:08:49 +04:00
unknown
29505f389b Merge spetrunia@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/psergey/mysql-5.0-bug16166-r2
2006-01-12 11:55:34 +03:00
unknown
9878a35a6a Fix typo bug in previous cset 2006-01-12 11:11:16 +03:00
unknown
8d9ffc6ad4 BUG#16166, "Can't use index_merge with FORCE INDEX": adjust the heurstics check to take into
account that "FORCE INDEX" disables full table scans, and not range/index_merge scans.
(with post-review fixes)


mysql-test/r/index_merge.result:
  Testcase for BUG#16166
mysql-test/t/index_merge.test:
  Testcase for BUG#16166
sql/sql_select.cc:
  BUG#16166: "Can't use index_merge with FORCE INDEX": adjust the heuristics check:
  if (force-index-is-used && there-is-possible-ref-access && 
  +    THERE IS NO POSSIBLE RANGE/INDEX_MERGE ACCESS)
  {
    ...
2006-01-12 10:48:27 +03:00
unknown
b49ea12f57 Merge mysql.com:/usr/home/bar/mysql-4.1.b15581
into  mysql.com:/usr/home/bar/mysql-5.0


mysql-test/t/ctype_utf8.test:
  Auto merged
mysql-test/r/ctype_utf8.result:
  After-merge fix.
sql/field.cc:
  After merge fix.
2006-01-12 11:38:09 +04:00
unknown
f00e5b36c7 Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/usr/home/bar/mysql-4.1.b15581
2006-01-12 11:13:34 +04:00
unknown
4eb2b162c5 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/alik/MySQL/devel/5.0-bug15103
2006-01-12 03:05:29 +03:00
unknown
f315b0b8a7 Fix for BUG#15103: SHOW TRIGGERS: small output alignment problem.
mysql-test/r/information_schema.result:
  Remove extra spaces from result file.
mysql-test/r/mysqldump.result:
  Remove extra spaces from result file.
mysql-test/r/rpl_ddl.result:
  Remove extra spaces from result file.
mysql-test/r/trigger-compat.result:
  Remove extra spaces from result file.
mysql-test/r/trigger-grant.result:
  Remove extra spaces from result file.
mysql-test/r/trigger.result:
  Remove extra spaces from result file.
sql/sql_yacc.yy:
  Remove leading spaces.
2006-01-12 03:02:52 +03:00
unknown
7c21527385 Merge rburnett@bk-internal.mysql.com:/home/bk/mysql-5.0
into  linux.site:/home/reggie/work/mysql-5.0
2006-01-11 16:34:51 -06:00
unknown
65bffb0f6d simple Windows compile fixes.
include/config-win.h:
  use the ll and ull postfix codes for create longlong and ulonglong
  symbols.  This allows ULL(a) and LL(a) to be used in more complex
  macro definitions than the previous definitions.  This may work on
  other compilers but we just tested on Visual 7.1 and 8.0
  
  Also, define HAVE_STRNLEN for all windows platforms.  Our own strnlen
  offers no performance improvements over the CRT version.
2006-01-11 16:18:11 -06:00
unknown
4e2e0c6d53 Fixed bug #15538: unchecked table absence caused server crash.
Absence of table in left part of LEFT/RIGHT join wasn't checked before
name resolution which resulted in NULL dereferencing and server crash.

Modified rules: 
"table_ref LEFT opt_outer JOIN_SYM table_ref" and "table_ref RIGHT opt_outer 
JOIN_SYM table_ref"
NULL check is moved before push_new_name_resolution_context()


sql/sql_yacc.yy:
  Fixed bug #15538: unchecked table absence caused server crash.
  Modified rules:
  "table_ref LEFT opt_outer JOIN_SYM table_ref" and "table_ref RIGHT opt_outer 
  JOIN_SYM table_ref"
  NULL check is moved before push_new_name_resolution_context()
mysql-test/r/select.result:
  Added test case for bug #15538: unchecked table absence caused server crash.
mysql-test/t/select.test:
  Added test case for bug #15538: unchecked table absence caused server crash.
2006-01-11 23:39:09 +03:00
unknown
ddcc6d7bd4 Fixed bug #15347: Wrong result of subselect when records cache and set
functions are involved.

When subselect is a join with set functions and no record have been found in
it, end_send_group() sets null_row for all tables in order aggregate functions 
to calculate their values correctly. Normally this null_row flag is cleared for 
each table in sub_select(), but flush_cached_records() doesn't do so.
Due to this all fields from the table processed by flush_cached_records() are 
always evaluated as nulls and whole select produces wrong result.

flush_cached_records() now clears null_row flag at the very beginning.


mysql-test/t/select.test:
  Added test case for bug #15347: Wrong result of subselect when records cache
  and set functions are involved
mysql-test/r/select.result:
  Added test case for bug #15347: Wrong result of subselect when records cache
  and set functions are involved
sql/sql_select.cc:
  Fixed bug #15347: Wrong result of subselect when records cache and set functions are involved
  flush_cached_records() now clears null_row flag at the very beginning.
2006-01-11 23:16:21 +03:00
unknown
593bed0d92 Fixed bug #15633: Evaluation of Item_equal for non-const table caused wrong
select result

Item equal objects are employed only at the optimize phase. Usually they are not
supposed to be evaluated.  Yet in some cases we call the method val_int() for
them. Here we have to take care of restricting the predicate such an object
represents f1=f2= ...=fn to the projection of known fields fi1=...=fik.

Added a check for field's table being const in Item_equal::val_int().
If the field's table is not const val_int() just skips that field when
evaluating Item_equal.


mysql-test/t/select.test:
  Added test case for bug #15633: Evaluation of Item_equal for non-const table caused wrong select result
mysql-test/r/select.result:
  Added test case for bug #15633: Evaluation of Item_equal for non-const table caused wrong select result
mysql-test/r/func_group.result:
  Corrected test result for bug #12882 after fix for bug#15633
sql/item_cmpfunc.h:
  Fixed bug #15633: Evaluation of Item_equal for non-const table caused wrong select result
  Added comment about fields from non-const tables in class description.
sql/item_cmpfunc.cc:
  Fixed bug #15633: Evaluation of Item_equal for non-const table caused wrong select result
  Added check for field's table being const in Item_equal::val_int().
2006-01-11 22:49:43 +03:00
unknown
c6993d67be Merge mysql.com:/opt/local/work/mysql-4.1-root
into  mysql.com:/opt/local/work/mysql-5.0-root


sql/item_strfunc.cc:
  Auto merged
sql/password.c:
  Manual merge
2006-01-11 17:49:56 +03:00
unknown
31ff9e9a10 A fix for Bug#13944 "libmysqlclient exporting sha1_result function":
rename sha1_* to mysql_sha1_*


include/sha1.h:
  rename sha1_* to mysql_sha1_*
mysys/sha1.c:
  rename sha1_* to mysql_sha1_*
sql/item_strfunc.cc:
  rename sha1_* to mysql_sha1_*
sql/password.c:
  rename sha1_* to mysql_sha1_*
2006-01-11 17:31:52 +03:00