Commit graph

10788 commits

Author SHA1 Message Date
unknown
6f1d63bfe0 Merge bk-internal:/home/bk/mysql-4.0/
into serg.mylan:/usr/home/serg/Abk/mysql-4.0


sql/mysqld.cc:
  Auto merged
2003-12-09 20:50:11 +01:00
unknown
7cfbf9e8f6 code cleanup after some reasoning
sql/mysqld.cc:
  code cleanup
2003-12-09 20:49:48 +01:00
unknown
4e85bf326e Add newline after pid in pidfile 2003-12-09 20:17:28 +02:00
unknown
4c8f7bd861 Post-merge fixes. 2003-12-09 19:05:41 +01:00
unknown
aaac51ea98 Merged 4.1 -> 5.0
include/mysql_com.h:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
myisam/mi_check.c:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/share/czech/errmsg.txt:
  Auto merged
sql/share/romanian/errmsg.txt:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
2003-12-09 19:00:34 +01:00
unknown
9388c41953 Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-4.1
into gw.mysql.r18.ru:/usr/home/ram/work/4.1.b1994
2003-12-09 22:00:33 +04:00
unknown
e0daf11201 Merge vvagin@bk-internal.mysql.com:/home/bk/mysql-4.1
into eagle.mysql.r18.ru:/home/vva/work/BUG_1688/mysql-4.1
2003-12-09 14:00:32 -04:00
unknown
32441953a7 Merge
mysql-test/t/create.test:
  Auto merged
mysql-test/r/create.result:
  SCCS merged
sql/sql_select.cc:
  SCCS merged
2003-12-09 13:34:57 -04:00
unknown
610fe7ae77 Merge bk-internal.mysql.com:/home/bk/mysql-4.0
into mysql.com:/my/mysql-4.0


sql/mysqld.cc:
  Auto merged
2003-12-09 16:21:43 +02:00
unknown
589657539c Don't limit number of tables in table cache 2003-12-09 16:21:23 +02:00
unknown
7b3d8cc93f Fix for the bugs:
#2005 Long decimal comparion bug.                                               
#2055 mysqldump should replace "-inf" numeric field values with "NULL"
2003-12-09 17:33:29 +04:00
unknown
56ea8bfd84 Fix for the bug #1994: mysqldump does not correctly dump UCS2 data. 2003-12-09 15:28:58 +04:00
unknown
ee89f1d340 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/my/mysql-4.1
2003-12-09 11:58:21 +02:00
unknown
6f96fb7956 test for the bug #1885: mysqldump does not dumps timestamp default. 2003-12-09 12:59:00 +04:00
unknown
c167af11e9 Fix for the bug #1885: mysqldump does not dumps timestamp default. 2003-12-09 12:36:57 +04:00
unknown
9a1cb59cd7 Create PID file with O_TRUNC, so that it is emptied before it is written to.
Otherwise, if the previous run ended with a crash, and the PID was 1234,
and you have rebooted the machine and the new PID is 99 then in the PID
file you will have 9934.
Note: users of mysqld_safe did not have the problem because this script
deletes the PID file before starting mysqld.
2003-12-08 20:53:46 +01:00
unknown
c121a73570 Merge gbichot@bk-internal.mysql.com:/home/bk/mysql-4.0
into mysql.com:/home/mysql_src/mysql-4.0
2003-12-08 20:47:42 +01:00
unknown
a50761a565 Fix for BUG#2045 "Sending SIGHUP to mysqld crashes it if running with --log-bin".
The constructor of Rotate_log_event used when we are rotating our binlog or
relay log, should not assume that there is a nonzero THD available.
For example, when we are reacting to SIGHUP, the THD is 0.
In fact we don't need to use the THD in this constructor;
we can do like for Stop_log_event, and use the minimal Log_event
constructor.
If we were allowed to put Unix-specific commands in the testsuite,
I'd add a test for this (<sigh>).


sql/log.cc:
  A comment to warn that thd can be 0.
  The part about LOG_EVENT_FORCED_ROTATE_F is just to avoid segfault;
  this flag is already removed in 4.1 anyway.
sql/log_event.cc:
  A comment.
sql/log_event.h:
  The constructor of Rotate_log_event used when we are rotating our binlog or
  relay log, should not assume that there is a nonzero THD available.
  For example, when we are reacting to SIGHUP, the THD is 0.
  In fact we don't need to use the THD in this constructor;
  we can do like for Stop_log_event, and use the minimal Log_event
  constructor.
  This fixes BUG#2045 
  "Sending SIGHUP to mysqld crashes it if running with --log-bin"
2003-12-08 16:18:25 +01:00
unknown
8b915a4316 post-merge fixes 2003-12-08 17:44:56 +04:00
unknown
adc470c290 Fixed two packaging bugs:
- postinstall of the Mac OS X PKG failed as a parameter for 
   mysql_install_db was changed for MySQL 4.1
 - postinstall of the Server RPM failed as mysql_create_system_tables was
   missing from the file list


support-files/MacOSX/postinstall.sh:
   - Fix parameter for mysql_install_db (it was changed from -IN-RPM to --rpm
     in the 4.1 tree)
support-files/mysql.spec.sh:
   - Added missing file mysql_create_system_tables to the server subpackage
2003-12-08 14:38:29 +01:00
unknown
4429ed7ec7 post-merge fixes
mysql-test/r/func_time.result:
  Auto merged
mysql-test/t/func_time.test:
  Auto merged
sql/item_create.cc:
  Auto merged
sql/item_create.h:
  Auto merged
sql/lex.h:
  Auto merged
2003-12-08 15:18:29 +04:00
unknown
417354eaa1 WL#530&531: TIMESTAMPADD, TIMESTAMPDIFF functions
Syntax for TIMESTAMPADD:

TIMESTAMPADD(interval, integer_expression, datetime_expression)

interval:= FRAC_SECOND | SECOND | MINUTE | HOUR | DAY | WEEK | MONTH | 
QUARTER | YEAR

Supported SQL_TSI_  prefix  (like SQL_TSI_SECOND)

Syntax for TIMESTAMPDIFF:

TIMESTAMPDIFF(interval, datetime_expression1, datetime_expression2)

interval:= FRAC_SECOND | SECOND | MINUTE | HOUR | DAY | WEEK | MONTH | 
QUARTER | YEAR

Supported SQL_TSI_  prefix  (like SQL_TSI_SECOND)


mysql-test/r/func_sapdb.result:
  Additional tests for timediff
mysql-test/r/func_time.result:
  Tests for timestampadd, timestampdiff functions
mysql-test/r/keywords.result:
  Test for new keywords
mysql-test/t/func_sapdb.test:
  Additional tests for timediff
mysql-test/t/func_time.test:
  Tests for timestampadd, timestampdiff functions
mysql-test/t/keywords.test:
  Test for new keywords
sql/item_create.cc:
  WL#530&531: TIMESTAMPADD, TIMESTAMPDIFF functions
sql/item_create.h:
  WL#530&531: TIMESTAMPADD, TIMESTAMPDIFF functions
sql/item_timefunc.cc:
  WL#530&531: TIMESTAMPADD, TIMESTAMPDIFF functions
sql/item_timefunc.h:
  WL#530&531: TIMESTAMPADD, TIMESTAMPDIFF functions
sql/lex.h:
  WL#530&531: TIMESTAMPADD, TIMESTAMPDIFF functions
sql/sql_yacc.yy:
  WL#530&531: TIMESTAMPADD, TIMESTAMPDIFF functions
2003-12-08 14:41:41 +04:00
unknown
6c0a24553e Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/home/kostja/mysql/mysql-4.1-root
2003-12-08 13:31:40 +03:00
unknown
f6f9b3496a commented why valgrind barks at the bug #1500 2003-12-08 13:30:14 +03:00
unknown
43b42ceee1 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/my/mysql-4.1


sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
strings/ctype-big5.c:
  Auto merged
strings/ctype-euc_kr.c:
  Auto merged
strings/ctype-gb2312.c:
  Auto merged
strings/ctype-gbk.c:
  Auto merged
strings/ctype-sjis.c:
  Auto merged
strings/ctype-ujis.c:
  Auto merged
2003-12-08 12:26:10 +02:00
unknown
e505696ffc Portability fixes for Windows
VC++Files/client/mysqlclient.dsp:
  Update for windows
VC++Files/libmysql/libmysql.dsp:
  Update for windows
VC++Files/strings/strings.dsp:
  Update for windows
libmysqld/lib_sql.cc:
  Update for windows
scripts/make_win_src_distribution.sh:
  Update for windows
scripts/mysql_install_db.sh:
  Update for windows
sql/mysqld.cc:
  Remove not used variable
sql/set_var.cc:
  Indentation cleanups
sql/share/czech/errmsg.txt:
  Fixed wrong delimiters
sql/share/danish/errmsg.txt:
  Fixed wrong delimiters
sql/share/dutch/errmsg.txt:
  Fixed wrong delimiters
sql/share/english/errmsg.txt:
  Fixed wrong delimiters
sql/share/estonian/errmsg.txt:
  Fixed wrong delimiters
sql/share/french/errmsg.txt:
  Fixed wrong delimiters
sql/share/greek/errmsg.txt:
  Fixed wrong delimiters
sql/share/hungarian/errmsg.txt:
  Fixed wrong delimiters
sql/share/italian/errmsg.txt:
  Fixed wrong delimiters
sql/share/japanese/errmsg.txt:
  Fixed wrong delimiters
sql/share/korean/errmsg.txt:
  Fixed wrong delimiters
sql/share/norwegian-ny/errmsg.txt:
  Fixed wrong delimiters
sql/share/norwegian/errmsg.txt:
  Fixed wrong delimiters
sql/share/polish/errmsg.txt:
  Fixed wrong delimiters
sql/share/portuguese/errmsg.txt:
  Fixed wrong delimiters
sql/share/romanian/errmsg.txt:
  Fixed wrong delimiters
sql/share/russian/errmsg.txt:
  Fixed wrong delimiters
sql/share/serbian/errmsg.txt:
  Fixed wrong delimiters
sql/share/slovak/errmsg.txt:
  Fixed wrong delimiters
sql/share/spanish/errmsg.txt:
  Fixed wrong delimiters
sql/share/swedish/errmsg.txt:
  Fixed wrong delimiters
sql/share/ukrainian/errmsg.txt:
  Fixed wrong delimiters
sql/sql_acl.cc:
  Removed compiler warnings
strings/ctype-big5.c:
  Removed compiler warnings (VC++)
strings/ctype-euc_kr.c:
  Removed compiler warnings (VC++)
strings/ctype-gb2312.c:
  Removed compiler warnings (VC++)
strings/ctype-gbk.c:
  Removed compiler warnings (VC++)
strings/ctype-sjis.c:
  Removed compiler warnings (VC++)
strings/ctype-ucs2.c:
  Removed compiler warnings (VC++)
strings/ctype-ujis.c:
  Removed compiler warnings (VC++)
2003-12-08 12:25:37 +02:00
unknown
8bf9ccb627 Fixed test for 'init_slave' variable 2003-12-08 12:10:30 +04:00
unknown
c335939203 post-merge fixes
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_show.cc:
  Auto merged
2003-12-08 09:44:04 +04:00
unknown
a0e4a6de56 Task ID 499:Add a new settable string variable(init_connect, init_slave)
to mysqld that is executed for all new connections.
(Similar to the client command: mysql_options(... MYSQL_INIT_COMMAND ...).


sql/mysql_priv.h:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/mysqld.cc:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/protocol.cc:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/set_var.cc:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/slave.cc:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/sql_class.cc:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/sql_class.h:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/sql_parse.cc:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
sql/sql_show.cc:
  Task ID	499:Add a new settable string variable(init_connect, init_slave)
  to mysqld that is executed for all new connections.
2003-12-08 09:13:14 +04:00
unknown
0ff62350f6 let chk_index() understand 2-level fulltext index format
sql/sql_table.cc:
  typo fixed
2003-12-07 20:36:45 +01:00
unknown
da3e63e126 Merge sgluhov@bk-internal.mysql.com:/home/bk/mysql-4.0
into gluh.mysql.r18.ru:/home/gluh/mysql-4.0.defweek


sql/mysqld.cc:
  Auto merged
2003-12-07 15:11:08 +04:00
unknown
468dcb6092 WL#1175: more default_week_formats for iso compatibility
New formats added for 'week()' function and 'default_week_format' option(4 - 7).
Next formats is supported now:
*Value* *Meaning*
  `0'     Week starts on Sunday; First Sunday of the year starts week 1.
  	  Week() returns 0-53.
  `1'     Week starts on Monday; Weeks numbered according to ISO 8601:1988.
	  Week() returns 0-53.
  `2'     Week starts on Sunday; First Sunday of the year starts week 1.
  	  Week() returns 1-53.
  `3'     Week starts on Monday; Weeks numbered according to ISO 8601:1988.
	  Week() returns 1-53.
  `4'     Week starts on Sunday; Weeks numbered according to ISO 8601:1988.
	  Week() returns 0-53.
  `5'     Week starts on Monday;  First Monday of the year starts week 1.
  	  Week() returns 0-53.
  `6'     Week starts on Sunday; Weeks numbered according to ISO 8601:1988.
	  Week() returns 1-53.
  `7'     Week starts on Monday;  First Monday of the year starts week 1.
  	  Week() returns 1-53.


mysql-test/r/func_time.result:
  Test for 'default_week_format' option and 'week' function
mysql-test/t/func_time.test:
  Test for 'default_week_format' option and 'week' function
sql/item_timefunc.cc:
  WL#1175 more default_week_formats for iso compatibility
sql/mysql_priv.h:
  WL#1175 more default_week_formats for iso compatibility
sql/mysqld.cc:
  WL#1175 more default_week_formats for iso compatibility
sql/time.cc:
  WL#1175 more default_week_formats for iso compatibility
2003-12-07 15:10:21 +04:00
unknown
f35c834d2f Merge sgluhov@bk-internal.mysql.com:/home/bk/mysql-4.0
into gluh.mysql.r18.ru:/home/gluh/mysql-4.0.pass


sql/sql_parse.cc:
  Auto merged
2003-12-07 13:36:29 +04:00
unknown
f3bf35ec03 QUERY_NO_GOOD_INDEX_USED and QUERY_NO_INDEX_USED moved from thd->lex.select_lex->options to thd->server_status
mysql-test/r/union.result:
  union and slow log tests
mysql-test/t/union.test:
  union and slow log tests
2003-12-06 23:21:09 +01:00
unknown
afbeb64e93 Merge bk-internal:/home/bk/mysql-4.1/
into serg.mylan:/usr/home/serg/Abk/mysql-4.1
2003-12-06 19:05:57 +01:00
unknown
2e82008bac fix for my_mbcharlen(charset, c) to return 1 for single-byte characters
(isn't it obvious ?)


mysys/charset.c:
  all charsets support my_mbcharlen - no need to protect it with use_mb()
sql/sql_load.cc:
  all charsets support my_mbcharlen - no need to protect it with use_mb()
2003-12-06 19:05:26 +01:00
unknown
7f9ba01f99 New test cases for BUG#1653 (recalling a procedure after replacing a faulty
table definition crashed), and recursive calls.


mysql-test/r/sp.result:
  New test cases for BUG#1653 and recursive calls.
mysql-test/t/sp.test:
  New test cases for BUG#1653 and recursive calls.
2003-12-05 18:52:33 +01:00
unknown
007d2e5a6b Fix for #1890 and #1959
This bug happens under Windows & Embedded server
Reason is that pthread_self() always returns NULL in this case.
This confuses thr_lock function and it doesn't stop
thread inserting in the write-locked table.

Global problem is that there's no way under Windows to get
unique thread handle for working thread.
Monty made a workaround for server - we store the thread's handle
we get when we create thread in the thread-specific variable.
This doesn't work with the embedded library for we don't control
thread creation there.

I added code that sets CurrentThreadId as the pthread_self
for the embedded library.
It seems to solve problem because it's unique and we don't use
pthread_self as a parameter for thread functions in embedded library. 


mysys/my_thr_init.c:
  setting of tmp->thread_self added
2003-12-05 21:45:19 +04:00
unknown
e425b98a01 typo fixed 2003-12-05 19:20:06 +03:00
unknown
b731040383 Post-merge fixes. 2003-12-05 14:45:48 +01:00
unknown
4cc0419030 Merged 4.1 -> 5.0
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
myisam/mi_check.c:
  Auto merged
myisam/myisamchk.c:
  Auto merged
myisam/sort.c:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
2003-12-05 13:11:50 +01:00
unknown
d4e3cc7219 attempt to make ULONGLONG_MAX work on Windows.
include/config-win.h:
  ULONGLONG_MAX definition added
include/my_global.h:
  comment about config-win.h added
2003-12-05 12:52:07 +03:00
unknown
07de836b44 Merge mysql.com:/home/kostja/mysql/mysql-4.1-root
into mysql.com:/home/kostja/mysql/mysql-4.1-max_prep_stmt_count


sql/mysqld.cc:
  Auto merged
2003-12-05 02:00:54 +03:00
unknown
997c4550f3 unused variable max_prep_stmt_count removed 2003-12-05 01:55:57 +03:00
unknown
cea764f387 Merge bk-internal.mysql.com:/home/bk/mysql-4.0
into mysql.com:/home/kostja/mysql/mysql-4.0-root
2003-12-05 01:29:20 +03:00
unknown
c135ce0255 test result fixed 2003-12-04 23:18:04 +01:00
unknown
7c3be1ba39 cleanup 2003-12-05 00:56:28 +03:00
unknown
1057ca5405 Merge gbichot@bk-internal.mysql.com:/home/bk/mysql-4.0
into mysql.com:/home/mysql_src/mysql-4.0
2003-12-04 22:44:13 +01:00
unknown
66927c51fa - Fix for BUG#1858 "SQL-Thread stops working when using optimize table":
we change THD::system_thread from a 'bool' to a bitmap to be able to
distinguish between delayed-insert threads and slave threads.
- Fix for BUG#1701 "Update from multiple tables" (one line in sql_parse.cc,
plus a new test rpl_multi_update.test). That's just adding an initialization.


sql/repl_failsafe.cc:
  comment to warn about this unused code
sql/slave.cc:
  Now thd->system_thread is a bitmap, not a bool.
sql/sql_class.h:
  'bool' for THD::system_thread is not accurate enough; sometimes we need
  to distinguish between delayed-insert threads and slave threads;
  so changing THD::system_thread to a bitmap (uint).
sql/sql_insert.cc:
  thd.system_thread is now a bitmap
sql/sql_parse.cc:
  We need to initialize thd->lex.select_lex.options in mysql_init_query();
  it's already initialized in dispatch_command() but replication calls
  mysql_parse() directly, thus bypassing dispatch_command().
  Not initing it here leads to a query influencing the next query,
  in the slave SQL thread.
  The initialization in dispatch_command() must be kept as this
  command uses the variable in tests, even when the command was not a
  query (i.e. when mysql_init_query() was not called).
2003-12-04 22:42:18 +01:00
unknown
cf45aa2b11 Merge bk-internal:/home/bk/mysql-4.1/
into serg.mylan:/usr/home/serg/Abk/mysql-4.1
2003-12-04 22:07:04 +01:00