mirror of
https://github.com/MariaDB/server.git
synced 2025-01-27 09:14:17 +01:00
merge 5.1->5.2
This commit is contained in:
commit
e5099a2c85
545 changed files with 14893 additions and 6230 deletions
15
.bzrignore
15
.bzrignore
|
@ -40,15 +40,15 @@
|
|||
*.dsp
|
||||
*.Po
|
||||
*.Plo
|
||||
*/*.dir/*
|
||||
*.dir/
|
||||
*/*_pure_*warnings
|
||||
*/.deps
|
||||
*/.libs/*
|
||||
*/.pure
|
||||
*/debug/*
|
||||
*/minsizerel/*
|
||||
*/release/*
|
||||
*/relwithdebinfo/*
|
||||
debug/
|
||||
MinSizeRel/
|
||||
Release/
|
||||
RelWithDebInfo/
|
||||
*~
|
||||
.*.swp
|
||||
./CMakeCache.txt
|
||||
|
@ -96,7 +96,7 @@ BitKeeper/tmp/gone
|
|||
BitKeeper/tmp
|
||||
BitKeeper/log
|
||||
BitKeeper/etc/SCCS
|
||||
CMakeFiles/*
|
||||
CMakeFiles/
|
||||
COPYING
|
||||
COPYING.LIB
|
||||
Docs/#manual.texi#
|
||||
|
@ -666,6 +666,9 @@ libmysqld/time.cc
|
|||
libmysqld/tztime.cc
|
||||
libmysqld/uniques.cc
|
||||
libmysqld/unireg.cc
|
||||
libmysqld/discover_xt.cc
|
||||
libmysqld/ha_pbxt.cc
|
||||
libmysqld/myxt_xt.cc
|
||||
libmysqltest/*.ds?
|
||||
libmysqltest/*.vcproj
|
||||
libmysqltest/mytest.c
|
||||
|
|
|
@ -34,6 +34,7 @@ EXTRA_DIST = FINISH.sh \
|
|||
compile-amd64-max \
|
||||
compile-amd64-max-sci \
|
||||
compile-amd64-valgrind-max \
|
||||
compile-bintar \
|
||||
compile-darwin-mwcc \
|
||||
compile-dist \
|
||||
compile-hpux11-parisc2-aCC \
|
||||
|
@ -80,7 +81,8 @@ EXTRA_DIST = FINISH.sh \
|
|||
compile-solaris-x86-32 \
|
||||
compile-solaris-x86-32-debug \
|
||||
compile-solaris-x86-32-debug-forte \
|
||||
compile-solaris-x86-forte-32
|
||||
compile-solaris-x86-forte-32 \
|
||||
util.sh
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -86,15 +86,9 @@ set -e
|
|||
#
|
||||
path=`dirname $0`
|
||||
. "$path/check-cpu"
|
||||
. "$path/util.sh"
|
||||
|
||||
export AM_MAKEFLAGS
|
||||
# Default to a parallel build, but only if AM_MAKEFLAGS is not set.
|
||||
# (So buildbots can easily disable this behaviour if required.)
|
||||
if test -z "$AM_MAKEFLAGS"
|
||||
then
|
||||
AM_MAKEFLAGS="-j 6"
|
||||
fi
|
||||
|
||||
get_make_parallel_flag
|
||||
|
||||
# SSL library to use.--with-ssl will select our bundled yaSSL
|
||||
# implementation of SSL. To use openSSl you will nee too point out
|
||||
|
|
81
BUILD/compile-bintar
Executable file
81
BUILD/compile-bintar
Executable file
|
@ -0,0 +1,81 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# MariaDB SQL server.
|
||||
# Copyright (C) 2010 Kristian Nielsen and Monty Program AB
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
|
||||
|
||||
# This script's purpose is to build the binary tarball packages for MariaDB
|
||||
# (currently only on Linux systems).
|
||||
#
|
||||
# Thus BUILD/compile-bintar from the appropriate source tarball will reproduce
|
||||
# such a release, provided the build environment (gcc version etc.) matches
|
||||
# (use scripts/make_binary_distribution after running this script to actually
|
||||
# create the binary tarball package).
|
||||
#
|
||||
# Note that packages are built from source tarballs not bzr checkouts.
|
||||
# Therefore, this script assumes autotools have already been run.
|
||||
#
|
||||
# We link libc dynamically, otherwise we get lots of problems loading
|
||||
# .so files at runtime (either system stuff like NSS, or server
|
||||
# plugins).
|
||||
#
|
||||
# We link libgcc statically (and avoid linking libstdc++ at all by
|
||||
# CXX=gcc), to avoid reduce nasty library version dependencies.
|
||||
|
||||
test -f Makefile && make distclean
|
||||
|
||||
path=`dirname $0`
|
||||
. $path/util.sh
|
||||
|
||||
SYSTEM_TYPE="$(uname -o)"
|
||||
MACHINE_TYPE="$(uname -m)"
|
||||
|
||||
# We cannot have a slash '/' in tarfile name.
|
||||
SYSTEM_TYPE="$(echo ${SYSTEM_TYPE} | sed -e 's/GNU\///')"
|
||||
|
||||
# Get correct options for architecture into CPUOPT.
|
||||
get_cpuopt
|
||||
# Get correct -j option into AM_MAKEFLAGS
|
||||
get_make_parallel_flag
|
||||
|
||||
# Use gcc rather than g++ to avoid linking libstdc++.so (which we don't need).
|
||||
COMP="gcc -static-libgcc"
|
||||
FLAGS="-O2 -fno-omit-frame-pointer -g -pipe -Wall $CPUOPT"
|
||||
|
||||
# Don't press on in case of error.
|
||||
set -e
|
||||
|
||||
CC="$COMP" CXX="$COMP" CFLAGS="$FLAGS" CXXFLAGS="$FLAGS" \
|
||||
./configure \
|
||||
--prefix=/usr/local/mysql \
|
||||
--exec-prefix=/usr/local/mysql \
|
||||
--libexecdir=/usr/local/mysql/bin \
|
||||
--localstatedir=/usr/local/mysql/data \
|
||||
\
|
||||
--with-comment="(MariaDB - http://mariadb.com/)" \
|
||||
--with-system-type="${SYSTEM_TYPE}" \
|
||||
--with-machine-type="${MACHINE_TYPE}" \
|
||||
\
|
||||
--enable-shared --enable-static \
|
||||
--with-client-ldflags=-static --with-mysqld-ldflags=-static \
|
||||
--enable-thread-safe-client --enable-local-infile --with-big-tables \
|
||||
--without-docs --with-extra-charsets=all \
|
||||
--with-libwrap --with-ssl --with-readline --with-libevent --with-zlib-dir=bundled \
|
||||
--with-partition --with-embedded-server \
|
||||
--with-plugins=max-no-ndb \
|
||||
--without-plugin-innodb_plugin
|
||||
|
||||
make $AM_MAKEFLAGS
|
0
BUILD/compile-solaris-amd64-debug-forte
Normal file → Executable file
0
BUILD/compile-solaris-amd64-debug-forte
Normal file → Executable file
0
BUILD/compile-solaris-x86-32
Normal file → Executable file
0
BUILD/compile-solaris-x86-32
Normal file → Executable file
0
BUILD/compile-solaris-x86-32-debug
Normal file → Executable file
0
BUILD/compile-solaris-x86-32-debug
Normal file → Executable file
0
BUILD/compile-solaris-x86-32-debug-forte
Normal file → Executable file
0
BUILD/compile-solaris-x86-32-debug-forte
Normal file → Executable file
0
BUILD/compile-solaris-x86-forte-32
Normal file → Executable file
0
BUILD/compile-solaris-x86-forte-32
Normal file → Executable file
48
BUILD/util.sh
Normal file
48
BUILD/util.sh
Normal file
|
@ -0,0 +1,48 @@
|
|||
# MariaDB SQL server.
|
||||
# Copyright (C) 2010 Kristian Nielsen and Monty Program AB
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
|
||||
# Setting cpu options.
|
||||
get_cpuopt () {
|
||||
case "$(uname -o)" in
|
||||
*Linux*)
|
||||
case "$(gcc -dumpmachine)" in
|
||||
x86_64-*)
|
||||
# gcc barfs on -march=... on x64
|
||||
CPUOPT="-m64 -mtune=generic"
|
||||
;;
|
||||
*)
|
||||
# we'd use i586 to not trip up mobile/lowpower devices
|
||||
CPUOPT="-m32 -march=i586 -mtune=generic"
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
*Solaris*)
|
||||
# ToDo: handle 32-bit build? For now default to 64-bit.
|
||||
CPUOPT="-D__sun -m64 -mtune=athlon64"
|
||||
;;
|
||||
esac
|
||||
return 0
|
||||
}
|
||||
|
||||
# Default to a parallel build, but only if AM_MAKEFLAGS is not set.
|
||||
# (So buildbots can easily disable this behaviour if required.)
|
||||
get_make_parallel_flag () {
|
||||
if test -z "$AM_MAKEFLAGS"
|
||||
then
|
||||
AM_MAKEFLAGS="-j 6"
|
||||
fi
|
||||
return 0
|
||||
}
|
|
@ -208,10 +208,6 @@ test-bt-fast:
|
|||
-cd mysql-test ; MTR_BUILD_THREAD=auto \
|
||||
@PERL@ ./mysql-test-run.pl $(MTR_EXTRA_OPTIONS) --force --comment=stress --suite=stress
|
||||
|
||||
test-bt-fast2:
|
||||
-cd mysql-test ; MTR_BUILD_THREAD=auto \
|
||||
@PERL@ ./mysql-test-run.pl $(MTR_EXTRA_OPTIONS) --force --comment=ps --ps-protocol --report-features
|
||||
|
||||
test-bt-debug:
|
||||
-cd mysql-test ; MTR_BUILD_THREAD=auto \
|
||||
@PERL@ ./mysql-test-run.pl $(MTR_EXTRA_OPTIONS) --comment=debug --force --timer \
|
||||
|
|
|
@ -4356,7 +4356,7 @@ com_status(String *buffer __attribute__((unused)),
|
|||
Don't remove "limit 1",
|
||||
it is protection againts SQL_SELECT_LIMIT=0
|
||||
*/
|
||||
if (mysql_store_result_for_lazy(&result))
|
||||
if (!mysql_store_result_for_lazy(&result))
|
||||
{
|
||||
MYSQL_ROW cur=mysql_fetch_row(result);
|
||||
if (cur)
|
||||
|
@ -4401,7 +4401,7 @@ com_status(String *buffer __attribute__((unused)),
|
|||
if (mysql_errno(&mysql) == CR_SERVER_GONE_ERROR)
|
||||
return 0;
|
||||
}
|
||||
if (mysql_store_result_for_lazy(&result))
|
||||
if (!mysql_store_result_for_lazy(&result))
|
||||
{
|
||||
MYSQL_ROW cur=mysql_fetch_row(result);
|
||||
if (cur)
|
||||
|
@ -4496,9 +4496,7 @@ server_version_string(MYSQL *con)
|
|||
*/
|
||||
|
||||
if (server_version == NULL)
|
||||
{
|
||||
server_version= strdup(mysql_get_server_info(con));
|
||||
}
|
||||
server_version= my_strdup(mysql_get_server_info(con), MYF(MY_WME));
|
||||
}
|
||||
|
||||
return server_version ? server_version : "";
|
||||
|
|
|
@ -1488,6 +1488,10 @@ static int parse_args(int *argc, char*** argv)
|
|||
*/
|
||||
static Exit_status safe_connect()
|
||||
{
|
||||
/* Close and old connections to MySQL */
|
||||
if (mysql)
|
||||
mysql_close(mysql);
|
||||
|
||||
mysql= mysql_init(NULL);
|
||||
|
||||
if (!mysql)
|
||||
|
|
|
@ -292,6 +292,25 @@ static int gettimeofday(struct timeval *tp, void *tzp)
|
|||
}
|
||||
#endif
|
||||
|
||||
void set_mysql_connect_options(MYSQL *mysql)
|
||||
{
|
||||
if (opt_compress)
|
||||
mysql_options(mysql,MYSQL_OPT_COMPRESS,NullS);
|
||||
#ifdef HAVE_OPENSSL
|
||||
if (opt_use_ssl)
|
||||
mysql_ssl_set(mysql, opt_ssl_key, opt_ssl_cert, opt_ssl_ca,
|
||||
opt_ssl_capath, opt_ssl_cipher);
|
||||
#endif
|
||||
if (opt_protocol)
|
||||
mysql_options(mysql,MYSQL_OPT_PROTOCOL,(char*)&opt_protocol);
|
||||
#ifdef HAVE_SMEM
|
||||
if (shared_memory_base_name)
|
||||
mysql_options(mysql,MYSQL_SHARED_MEMORY_BASE_NAME,shared_memory_base_name);
|
||||
#endif
|
||||
mysql_options(mysql, MYSQL_SET_CHARSET_NAME, default_charset);
|
||||
}
|
||||
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
MYSQL mysql;
|
||||
|
@ -323,20 +342,7 @@ int main(int argc, char **argv)
|
|||
exit(1);
|
||||
}
|
||||
mysql_init(&mysql);
|
||||
if (opt_compress)
|
||||
mysql_options(&mysql,MYSQL_OPT_COMPRESS,NullS);
|
||||
#ifdef HAVE_OPENSSL
|
||||
if (opt_use_ssl)
|
||||
mysql_ssl_set(&mysql, opt_ssl_key, opt_ssl_cert, opt_ssl_ca,
|
||||
opt_ssl_capath, opt_ssl_cipher);
|
||||
#endif
|
||||
if (opt_protocol)
|
||||
mysql_options(&mysql,MYSQL_OPT_PROTOCOL,(char*)&opt_protocol);
|
||||
#ifdef HAVE_SMEM
|
||||
if (shared_memory_base_name)
|
||||
mysql_options(&mysql,MYSQL_SHARED_MEMORY_BASE_NAME,shared_memory_base_name);
|
||||
#endif
|
||||
mysql_options(&mysql, MYSQL_SET_CHARSET_NAME, default_charset);
|
||||
set_mysql_connect_options(&mysql);
|
||||
|
||||
if (!opt_only_print)
|
||||
{
|
||||
|
@ -1815,6 +1821,7 @@ pthread_handler_t run_task(void *p)
|
|||
my_progname, mysql_error(mysql));
|
||||
exit(0);
|
||||
}
|
||||
set_mysql_connect_options(mysql);
|
||||
|
||||
if (mysql_thread_init())
|
||||
{
|
||||
|
@ -1855,7 +1862,6 @@ limit_not_met:
|
|||
my_progname, mysql_error(mysql));
|
||||
exit(0);
|
||||
}
|
||||
|
||||
if (slap_connect(mysql))
|
||||
goto end;
|
||||
}
|
||||
|
@ -2223,6 +2229,7 @@ slap_connect(MYSQL *mysql)
|
|||
int x, connect_error= 1;
|
||||
for (x= 0; x < 10; x++)
|
||||
{
|
||||
set_mysql_connect_options(mysql);
|
||||
if (mysql_real_connect(mysql, host, user, opt_password,
|
||||
create_schema_string,
|
||||
opt_mysql_port,
|
||||
|
|
|
@ -657,7 +657,9 @@ public:
|
|||
}
|
||||
|
||||
while ((bytes= fread(buf, 1, sizeof(buf), m_file)) > 0)
|
||||
fwrite(buf, 1, bytes, stderr);
|
||||
if (fwrite(buf, 1, bytes, stderr))
|
||||
die("Failed to write to '%s', errno: %d",
|
||||
m_file_name, errno);
|
||||
|
||||
if (!lines)
|
||||
{
|
||||
|
|
|
@ -267,7 +267,6 @@ dnl we have to recompile these modules when we want to
|
|||
dnl to compile server parts with the different #defines
|
||||
dnl Normally it happens when we compile the embedded server
|
||||
dnl Thus one should mark such files in his handler using this macro
|
||||
dnl (currently only one such a file per plugin is supported)
|
||||
dnl
|
||||
dnl ---------------------------------------------------------------------------
|
||||
|
||||
|
@ -464,10 +463,12 @@ dnl Although this is "pretty", it breaks libmysqld build
|
|||
[with_plugin_]$2=yes
|
||||
AC_MSG_RESULT([yes])
|
||||
m4_ifdef([$11], [
|
||||
condition_dependent_plugin_modules="$condition_dependent_plugin_modules m4_bregexp($11, [[^/]+$], [\&])"
|
||||
condition_dependent_plugin_objects="$condition_dependent_plugin_objects m4_bregexp($11, [[^/]+\.], [\&o])"
|
||||
condition_dependent_plugin_links="$condition_dependent_plugin_links $6/$11"
|
||||
condition_dependent_plugin_includes="$condition_dependent_plugin_includes -I[\$(top_srcdir)]/$6/m4_bregexp($11, [^.+[/$]], [\&])"
|
||||
m4_foreach([plugin], [$11], [
|
||||
condition_dependent_plugin_modules="$condition_dependent_plugin_modules m4_bregexp(plugin, [[^/]+$], [\&])"
|
||||
condition_dependent_plugin_objects="$condition_dependent_plugin_objects m4_bregexp(plugin, [[^/]+\.], [\&o])"
|
||||
condition_dependent_plugin_links="$condition_dependent_plugin_links $6/plugin"
|
||||
condition_dependent_plugin_includes="$condition_dependent_plugin_includes -I[\$(top_srcdir)]/$6/m4_bregexp(plugin, [^.+[/$]], [\&])"
|
||||
])
|
||||
])
|
||||
fi
|
||||
fi
|
||||
|
|
16
configure.in
16
configure.in
|
@ -18,6 +18,12 @@ AC_CANONICAL_SYSTEM
|
|||
AM_INIT_AUTOMAKE(mysql, 5.2.0-MariaDB-alpha)
|
||||
AM_CONFIG_HEADER([include/config.h:config.h.in])
|
||||
|
||||
# Request support for automake silent-rules if available.
|
||||
# Default to verbose output. One can use the configure-time
|
||||
# option --enable-silent-rules or make V=0 to activate
|
||||
# silent rules.
|
||||
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([no])])
|
||||
|
||||
PROTOCOL_VERSION=10
|
||||
DOT_FRM_VERSION=6
|
||||
# See the libtool docs for information on how to do shared lib versions.
|
||||
|
@ -224,14 +230,6 @@ then
|
|||
GXX="no"
|
||||
fi
|
||||
|
||||
if test "$ac_cv_prog_gcc" = "yes"
|
||||
then
|
||||
AS="$CC -c"
|
||||
AC_SUBST(AS)
|
||||
else
|
||||
AC_PATH_PROG(AS, as, as)
|
||||
fi
|
||||
|
||||
# Still need ranlib for readline; local static use only so no libtool.
|
||||
AC_PROG_RANLIB
|
||||
# We use libtool
|
||||
|
@ -688,7 +686,7 @@ AC_ARG_ENABLE(assembler,
|
|||
|
||||
AC_MSG_CHECKING(if we should use assembler functions)
|
||||
# For now we only support assembler on i386 and sparc systems
|
||||
AM_CONDITIONAL(ASSEMBLER_x86, test "$ENABLE_ASSEMBLER" = "yes" -a "$BASE_MACHINE_TYPE" = "i386" && $AS strings/strings-x86.s -o checkassembler >/dev/null 2>&1 && test -f checkassembler && (rm -f checkassembler; exit 0;))
|
||||
AM_CONDITIONAL(ASSEMBLER_x86, test "$ENABLE_ASSEMBLER" = "yes" -a "$BASE_MACHINE_TYPE" = "i386" && $CCAS $CCASFLAGS -c strings/strings-x86.s -o checkassembler >/dev/null 2>&1 && test -f checkassembler && (rm -f checkassembler; exit 0;))
|
||||
AM_CONDITIONAL(ASSEMBLER_sparc32, test "$ENABLE_ASSEMBLER" = "yes" -a "$BASE_MACHINE_TYPE" = "sparc")
|
||||
AM_CONDITIONAL(ASSEMBLER_sparc64, test "$ENABLE_ASSEMBLER" = "yes" -a "$BASE_MACHINE_TYPE" = "sparcv9")
|
||||
AM_CONDITIONAL(ASSEMBLER, test "$ASSEMBLER_x86_TRUE" = "" -o "$ASSEMBLER_sparc32_TRUE" = "")
|
||||
|
|
|
@ -660,7 +660,7 @@ static ha_checksum checksum_format_specifier(const char* msg)
|
|||
case 'u':
|
||||
case 'x':
|
||||
case 's':
|
||||
chksum= my_checksum(chksum, start, (uint) (p - start));
|
||||
chksum= my_checksum(chksum, start, (uint) (p + 1 - start));
|
||||
start= 0; /* Not in format specifier anymore */
|
||||
break;
|
||||
|
||||
|
@ -1030,8 +1030,10 @@ static char *parse_text_line(char *pos)
|
|||
{
|
||||
int i, nr;
|
||||
char *row= pos;
|
||||
size_t len;
|
||||
DBUG_ENTER("parse_text_line");
|
||||
|
||||
len= strlen (pos);
|
||||
while (*pos)
|
||||
{
|
||||
if (*pos == '\\')
|
||||
|
@ -1039,11 +1041,11 @@ static char *parse_text_line(char *pos)
|
|||
switch (*++pos) {
|
||||
case '\\':
|
||||
case '"':
|
||||
VOID(strmov(pos - 1, pos));
|
||||
VOID(memmove (pos - 1, pos, len - (row - pos)));
|
||||
break;
|
||||
case 'n':
|
||||
pos[-1]= '\n';
|
||||
VOID(strmov(pos, pos + 1));
|
||||
VOID(memmove (pos, pos + 1, len - (row - pos)));
|
||||
break;
|
||||
default:
|
||||
if (*pos >= '0' && *pos < '8')
|
||||
|
@ -1053,10 +1055,10 @@ static char *parse_text_line(char *pos)
|
|||
nr= nr * 8 + (*(pos++) - '0');
|
||||
pos -= i;
|
||||
pos[-1]= nr;
|
||||
VOID(strmov(pos, pos + i));
|
||||
VOID(memmove (pos, pos + i, len - (row - pos)));
|
||||
}
|
||||
else if (*pos)
|
||||
VOID(strmov(pos - 1, pos)); /* Remove '\' */
|
||||
VOID(memmove (pos - 1, pos, len - (row - pos))); /* Remove '\' */
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
|
@ -140,7 +140,7 @@ devpoll_init(struct event_base *base)
|
|||
return (NULL);
|
||||
|
||||
if (getrlimit(RLIMIT_NOFILE, &rl) == 0 &&
|
||||
rl.rlim_cur != RLIM_INFINITY)
|
||||
(unsigned long long) rl.rlim_cur != (unsigned long long) RLIM_INFINITY)
|
||||
nfiles = rl.rlim_cur - 1;
|
||||
|
||||
/* Initialize the kernel queue */
|
||||
|
|
|
@ -25,12 +25,12 @@
|
|||
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#ifdef HAVE_SYS_TIME_H
|
||||
#include <sys/time.h>
|
||||
#endif
|
||||
|
|
|
@ -60,7 +60,7 @@ void SetErrorString(YasslError error, char* buffer)
|
|||
using namespace TaoCrypt;
|
||||
const int max = MAX_ERROR_SZ; // shorthand
|
||||
|
||||
switch (error) {
|
||||
switch ((int) error) {
|
||||
|
||||
// yaSSL proper errors
|
||||
case range_error :
|
||||
|
|
|
@ -305,6 +305,7 @@ private:
|
|||
bool ValidateSignature(SignerList*);
|
||||
bool ConfirmSignature(Source&);
|
||||
void GetKey();
|
||||
char* AddTag(char*, const char*, const char*, word32, word32);
|
||||
void GetName(NameType);
|
||||
void GetValidity();
|
||||
void GetDate(DateType);
|
||||
|
|
|
@ -652,6 +652,25 @@ word32 CertDecoder::GetDigest()
|
|||
}
|
||||
|
||||
|
||||
// memory length checked add tag to buffer
|
||||
char* CertDecoder::AddTag(char* ptr, const char* buf_end, const char* tag_name,
|
||||
word32 tag_name_length, word32 tag_value_length)
|
||||
{
|
||||
if (ptr + tag_name_length + tag_value_length > buf_end) {
|
||||
source_.SetError(CONTENT_E);
|
||||
return 0;
|
||||
}
|
||||
|
||||
memcpy(ptr, tag_name, tag_name_length);
|
||||
ptr += tag_name_length;
|
||||
|
||||
memcpy(ptr, source_.get_current(), tag_value_length);
|
||||
ptr += tag_value_length;
|
||||
|
||||
return ptr;
|
||||
}
|
||||
|
||||
|
||||
// process NAME, either issuer or subject
|
||||
void CertDecoder::GetName(NameType nt)
|
||||
{
|
||||
|
@ -659,11 +678,22 @@ void CertDecoder::GetName(NameType nt)
|
|||
|
||||
SHA sha;
|
||||
word32 length = GetSequence(); // length of all distinguished names
|
||||
assert (length < ASN_NAME_MAX);
|
||||
|
||||
if (length >= ASN_NAME_MAX)
|
||||
return;
|
||||
length += source_.get_index();
|
||||
|
||||
char* ptr = (nt == ISSUER) ? issuer_ : subject_;
|
||||
word32 idx = 0;
|
||||
char* ptr;
|
||||
char* buf_end;
|
||||
|
||||
if (nt == ISSUER) {
|
||||
ptr = issuer_;
|
||||
buf_end = ptr + sizeof(issuer_) - 1; // 1 byte for trailing 0
|
||||
}
|
||||
else {
|
||||
ptr = subject_;
|
||||
buf_end = ptr + sizeof(subject_) - 1; // 1 byte for trailing 0
|
||||
}
|
||||
|
||||
while (source_.get_index() < length) {
|
||||
GetSet();
|
||||
|
@ -685,47 +715,36 @@ void CertDecoder::GetName(NameType nt)
|
|||
byte id = source_.next();
|
||||
b = source_.next(); // strType
|
||||
word32 strLen = GetLength(source_);
|
||||
bool copy = false;
|
||||
|
||||
if (id == COMMON_NAME) {
|
||||
memcpy(&ptr[idx], "/CN=", 4);
|
||||
idx += 4;
|
||||
copy = true;
|
||||
}
|
||||
else if (id == SUR_NAME) {
|
||||
memcpy(&ptr[idx], "/SN=", 4);
|
||||
idx += 4;
|
||||
copy = true;
|
||||
}
|
||||
else if (id == COUNTRY_NAME) {
|
||||
memcpy(&ptr[idx], "/C=", 3);
|
||||
idx += 3;
|
||||
copy = true;
|
||||
}
|
||||
else if (id == LOCALITY_NAME) {
|
||||
memcpy(&ptr[idx], "/L=", 3);
|
||||
idx += 3;
|
||||
copy = true;
|
||||
}
|
||||
else if (id == STATE_NAME) {
|
||||
memcpy(&ptr[idx], "/ST=", 4);
|
||||
idx += 4;
|
||||
copy = true;
|
||||
}
|
||||
else if (id == ORG_NAME) {
|
||||
memcpy(&ptr[idx], "/O=", 3);
|
||||
idx += 3;
|
||||
copy = true;
|
||||
}
|
||||
else if (id == ORGUNIT_NAME) {
|
||||
memcpy(&ptr[idx], "/OU=", 4);
|
||||
idx += 4;
|
||||
copy = true;
|
||||
}
|
||||
|
||||
if (copy) {
|
||||
memcpy(&ptr[idx], source_.get_current(), strLen);
|
||||
idx += strLen;
|
||||
switch (id) {
|
||||
case COMMON_NAME:
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/CN=", 4, strLen)))
|
||||
return;
|
||||
break;
|
||||
case SUR_NAME:
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/SN=", 4, strLen)))
|
||||
return;
|
||||
break;
|
||||
case COUNTRY_NAME:
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/C=", 3, strLen)))
|
||||
return;
|
||||
break;
|
||||
case LOCALITY_NAME:
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/L=", 3, strLen)))
|
||||
return;
|
||||
break;
|
||||
case STATE_NAME:
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/ST=", 4, strLen)))
|
||||
return;
|
||||
break;
|
||||
case ORG_NAME:
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/O=", 3, strLen)))
|
||||
return;
|
||||
break;
|
||||
case ORGUNIT_NAME:
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/OU=", 4, strLen)))
|
||||
return;
|
||||
break;
|
||||
}
|
||||
|
||||
sha.Update(source_.get_current(), strLen);
|
||||
|
@ -740,17 +759,15 @@ void CertDecoder::GetName(NameType nt)
|
|||
word32 length = GetLength(source_);
|
||||
|
||||
if (email) {
|
||||
memcpy(&ptr[idx], "/emailAddress=", 14);
|
||||
idx += 14;
|
||||
|
||||
memcpy(&ptr[idx], source_.get_current(), length);
|
||||
idx += length;
|
||||
if (!(ptr = AddTag(ptr, buf_end, "/emailAddress=", 14, length)))
|
||||
return;
|
||||
}
|
||||
|
||||
source_.advance(length);
|
||||
}
|
||||
}
|
||||
ptr[idx++] = 0;
|
||||
|
||||
*ptr = 0;
|
||||
|
||||
if (nt == ISSUER)
|
||||
sha.Final(issuerHash_);
|
||||
|
|
|
@ -62,7 +62,8 @@ void ft_free_stopwords(void);
|
|||
#define FT_SORTED 2
|
||||
#define FT_EXPAND 4 /* query expansion */
|
||||
|
||||
FT_INFO *ft_init_search(uint,void *, uint, uchar *, uint,CHARSET_INFO *, uchar *);
|
||||
FT_INFO *ft_init_search(uint,void *, uint, uchar *, size_t,
|
||||
CHARSET_INFO *, uchar *);
|
||||
my_bool ft_boolean_check_syntax_string(const uchar *);
|
||||
|
||||
/* Internal symbols for fulltext between maria and MyISAM */
|
||||
|
|
|
@ -462,7 +462,7 @@ void maria_versioning(MARIA_HA *info, my_bool versioning);
|
|||
void maria_ignore_trids(MARIA_HA *info);
|
||||
|
||||
/* fulltext functions */
|
||||
FT_INFO *maria_ft_init_search(uint,void *, uint, uchar *, uint,
|
||||
FT_INFO *maria_ft_init_search(uint,void *, uint, uchar *, size_t,
|
||||
CHARSET_INFO *, uchar *);
|
||||
|
||||
/* 'Almost-internal' Maria functions */
|
||||
|
|
|
@ -543,9 +543,9 @@ void safe_mutex_free_deadlock_data(safe_mutex_t *mp);
|
|||
#else
|
||||
#define my_pthread_mutex_init(A,B,C,D) pthread_mutex_init((A),(B))
|
||||
#define my_pthread_mutex_lock(A,B) pthread_mutex_lock(A)
|
||||
#define safe_mutex_assert_owner(mp)
|
||||
#define safe_mutex_assert_not_owner(mp)
|
||||
#define safe_mutex_free_deadlock_data(mp)
|
||||
#define safe_mutex_assert_owner(mp) do {} while(0)
|
||||
#define safe_mutex_assert_not_owner(mp) do {} while(0)
|
||||
#define safe_mutex_free_deadlock_data(mp) do {} while(0)
|
||||
#endif /* SAFE_MUTEX */
|
||||
|
||||
#if defined(MY_PTHREAD_FASTMUTEX) && !defined(SAFE_MUTEX)
|
||||
|
|
|
@ -558,16 +558,6 @@ unsigned long STDCALL mysql_real_escape_string(MYSQL *mysql,
|
|||
char *to,const char *from,
|
||||
unsigned long length);
|
||||
void STDCALL mysql_debug(const char *debug);
|
||||
char * STDCALL mysql_odbc_escape_string(MYSQL *mysql,
|
||||
char *to,
|
||||
unsigned long to_length,
|
||||
const char *from,
|
||||
unsigned long from_length,
|
||||
void *param,
|
||||
char *
|
||||
(*extend_buffer)
|
||||
(void *, char *to,
|
||||
unsigned long *length));
|
||||
void STDCALL myodbc_remove_escape(MYSQL *mysql,char *name);
|
||||
unsigned int STDCALL mysql_thread_safe(void);
|
||||
my_bool STDCALL mysql_embedded(void);
|
||||
|
|
|
@ -518,16 +518,6 @@ unsigned long mysql_real_escape_string(MYSQL *mysql,
|
|||
char *to,const char *from,
|
||||
unsigned long length);
|
||||
void mysql_debug(const char *debug);
|
||||
char * mysql_odbc_escape_string(MYSQL *mysql,
|
||||
char *to,
|
||||
unsigned long to_length,
|
||||
const char *from,
|
||||
unsigned long from_length,
|
||||
void *param,
|
||||
char *
|
||||
(*extend_buffer)
|
||||
(void *, char *to,
|
||||
unsigned long *length));
|
||||
void myodbc_remove_escape(MYSQL *mysql,char *name);
|
||||
unsigned int mysql_thread_safe(void);
|
||||
my_bool mysql_embedded(void);
|
||||
|
|
|
@ -123,8 +123,8 @@ struct st_VioSSLFd
|
|||
SSL_CTX *ssl_context;
|
||||
};
|
||||
|
||||
int sslaccept(struct st_VioSSLFd*, Vio *, long timeout);
|
||||
int sslconnect(struct st_VioSSLFd*, Vio *, long timeout);
|
||||
int sslaccept(struct st_VioSSLFd*, Vio *, long timeout, char *error_string);
|
||||
int sslconnect(struct st_VioSSLFd*, Vio *, long timeout, char *error_string);
|
||||
|
||||
struct st_VioSSLFd
|
||||
*new_VioSSLConnectorFd(const char *key_file, const char *cert_file,
|
||||
|
@ -225,8 +225,8 @@ struct st_vio
|
|||
#endif /* HAVE_SMEM */
|
||||
#ifdef _WIN32
|
||||
OVERLAPPED pipe_overlapped;
|
||||
DWORD read_timeout_millis;
|
||||
DWORD write_timeout_millis;
|
||||
DWORD read_timeout_ms;
|
||||
DWORD write_timeout_ms;
|
||||
#endif
|
||||
};
|
||||
#endif /* vio_violite_h_ */
|
||||
|
|
|
@ -1642,20 +1642,6 @@ mysql_real_escape_string(MYSQL *mysql, char *to,const char *from,
|
|||
return (uint) escape_string_for_mysql(mysql->charset, to, 0, from, length);
|
||||
}
|
||||
|
||||
|
||||
char * STDCALL
|
||||
mysql_odbc_escape_string(MYSQL *mysql __attribute__((unused)),
|
||||
char *to __attribute__((unused)),
|
||||
ulong to_length __attribute__((unused)),
|
||||
const char *from __attribute__((unused)),
|
||||
ulong from_length __attribute__((unused)),
|
||||
void *param __attribute__((unused)),
|
||||
char * (*extend_buffer)(void *, char *, ulong *)
|
||||
__attribute__((unused)))
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void STDCALL
|
||||
myodbc_remove_escape(MYSQL *mysql,char *name)
|
||||
{
|
||||
|
|
|
@ -78,7 +78,6 @@ EXPORTS
|
|||
mysql_next_result
|
||||
mysql_num_fields
|
||||
mysql_num_rows
|
||||
mysql_odbc_escape_string
|
||||
mysql_options
|
||||
mysql_stmt_param_count
|
||||
mysql_stmt_param_metadata
|
||||
|
|
|
@ -50,7 +50,6 @@ EXPORTS
|
|||
mysql_next_result
|
||||
mysql_num_fields
|
||||
mysql_num_rows
|
||||
mysql_odbc_escape_string
|
||||
mysql_options
|
||||
mysql_ping
|
||||
mysql_query
|
||||
|
|
|
@ -13,15 +13,13 @@ funcs_1.ndb* # joro : NDB tests marked as experiment
|
|||
funcs_2.ndb_charset # joro : NDB tests marked as experimental as agreed with bochklin
|
||||
|
||||
main.ctype_gbk_binlog @solaris # Bug#46010: main.ctype_gbk_binlog fails sporadically : Table 't2' already exists
|
||||
main.innodb-autoinc* # Bug#47809 2009-10-04 joro innodb-autoinc.test fails with valgrind errors with the innodb plugin
|
||||
main.plugin_load @solaris # Bug#42144
|
||||
|
||||
ndb.* # joro : NDB tests marked as experimental as agreed with bochklin
|
||||
|
||||
rpl.rpl_cross_version* # Bug #43913 2009-10-26 joro rpl_cross_version can't pass on conflicts complainig clash with --slave-load-tm
|
||||
rpl.rpl_get_master_version_and_clock* # Bug#46931 2009-08-26 alik rpl.rpl_get_master_version_and_clock fails on hpux11.31
|
||||
rpl.rpl_cross_version* # Bug#48340 2009-12-01 Daogang rpl_cross_version: Found warnings/errors in server log file!
|
||||
rpl.rpl_get_master_version_and_clock* # Bug #49191 2009-12-01 Daogang rpl_get_master_version_and_clock failed on PB2: COM_REGISTER_SLAVE failed
|
||||
rpl.rpl_innodb_bug28430* @solaris # Bug#46029
|
||||
rpl.rpl_row_create_table* # Bug#45576: rpl_row_create_table fails on PB2
|
||||
rpl.rpl_trigger* # Bug#47810 2009-10-04 joro rpl.rpl_trigger.test fails with valgrind errors with the innodb plugin
|
||||
|
||||
rpl_ndb.* # joro : NDB tests marked as experimental as agreed with bochklin
|
||||
|
|
|
@ -407,13 +407,21 @@ sync_slave_with_master;
|
|||
###########################################
|
||||
# Bug#22234, Bug#23907 Extra Slave Col is not
|
||||
# erroring on extra col with no default values.
|
||||
########################################################
|
||||
###############################################################
|
||||
# Error reaction is up to sql_mode of the slave sql (bug#38173)
|
||||
#--echo *** Create t9 on slave ***
|
||||
# Please, check BUG#47741 to see why you are not testing NDB.
|
||||
if (`SELECT $engine_type != 'NDB'`)
|
||||
{
|
||||
STOP SLAVE;
|
||||
RESET SLAVE;
|
||||
eval CREATE TABLE t9 (a INT KEY, b BLOB, c CHAR(5),
|
||||
d TIMESTAMP,
|
||||
e INT NOT NULL) ENGINE=$engine_type;
|
||||
e INT NOT NULL,
|
||||
f text not null,
|
||||
g text,
|
||||
h blob not null,
|
||||
i blob) ENGINE=$engine_type;
|
||||
|
||||
--echo *** Create t9 on Master ***
|
||||
connection master;
|
||||
|
@ -428,16 +436,28 @@ START SLAVE;
|
|||
--echo *** Master Data Insert ***
|
||||
connection master;
|
||||
set @b1 = 'b1b1b1b1';
|
||||
|
||||
set @b1 = concat(@b1,@b1);
|
||||
INSERT INTO t9 () VALUES(1,@b1,'Kyle'),(2,@b1,'JOE'),(3,@b1,'QA');
|
||||
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
# the test would stop slave if @@sql_mode for the sql thread
|
||||
# was set to strict. Otherwise, as with this tests setup,
|
||||
# the implicit defaults will be inserted into fields even though
|
||||
# they are declared without DEFAULT clause.
|
||||
|
||||
sync_slave_with_master;
|
||||
select * from t9;
|
||||
|
||||
# todo: fix Bug #43992 slave sql thread can't tune own sql_mode ...
|
||||
# and add/restore waiting for stop test
|
||||
|
||||
#--source include/wait_for_slave_sql_to_stop.inc
|
||||
#--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
#--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
#--query_vertical SHOW SLAVE STATUS
|
||||
#SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
#START SLAVE;
|
||||
}
|
||||
|
||||
#--echo *** Drop t9 ***
|
||||
#connection master;
|
||||
|
|
364
mysql-test/extra/rpl_tests/rpl_not_null.test
Normal file
364
mysql-test/extra/rpl_tests/rpl_not_null.test
Normal file
|
@ -0,0 +1,364 @@
|
|||
#################################################################################
|
||||
# This test checks if the replication between "null" fields to either "null"
|
||||
# fields or "not null" fields works properly. In the first case, the execution
|
||||
# should work fine. In the second case, it may fail according to the sql_mode
|
||||
# being used.
|
||||
#
|
||||
# The test is devided in three main parts:
|
||||
#
|
||||
# 1 - NULL --> NULL (no failures)
|
||||
# 2 - NULL --> NOT NULL ( sql-mode = STRICT and failures)
|
||||
# 3 - NULL --> NOT NULL ( sql-mode != STRICT and no failures)
|
||||
#
|
||||
#################################################################################
|
||||
connection master;
|
||||
|
||||
SET SQL_LOG_BIN= 0;
|
||||
eval CREATE TABLE t1(`a` INT, `b` DATE DEFAULT NULL,
|
||||
`c` INT DEFAULT NULL,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
eval CREATE TABLE t2(`a` INT, `b` DATE DEFAULT NULL,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
eval CREATE TABLE t3(`a` INT, `b` DATE DEFAULT NULL,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
eval CREATE TABLE t4(`a` INT, `b` DATE DEFAULT NULL,
|
||||
`c` INT DEFAULT NULL,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
SET SQL_LOG_BIN= 1;
|
||||
|
||||
connection slave;
|
||||
|
||||
eval CREATE TABLE t1(`a` INT, `b` DATE DEFAULT NULL,
|
||||
`c` INT DEFAULT NULL,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
eval CREATE TABLE t2(`a` INT, `b` DATE DEFAULT NULL,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
eval CREATE TABLE t3(`a` INT, `b` DATE DEFAULT '0000-00-00',
|
||||
`c` INT DEFAULT 500,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
eval CREATE TABLE t4(`a` INT, `b` DATE DEFAULT '0000-00-00',
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
--echo ************* EXECUTION WITH INSERTS *************
|
||||
connection master;
|
||||
INSERT INTO t1(a,b,c) VALUES (1, null, 1);
|
||||
INSERT INTO t1(a,b,c) VALUES (2,'1111-11-11', 2);
|
||||
INSERT INTO t1(a,b) VALUES (3, null);
|
||||
INSERT INTO t1(a,c) VALUES (4, 4);
|
||||
INSERT INTO t1(a) VALUES (5);
|
||||
|
||||
INSERT INTO t2(a,b) VALUES (1, null);
|
||||
INSERT INTO t2(a,b) VALUES (2,'1111-11-11');
|
||||
INSERT INTO t2(a) VALUES (3);
|
||||
|
||||
INSERT INTO t3(a,b) VALUES (1, null);
|
||||
INSERT INTO t3(a,b) VALUES (2,'1111-11-11');
|
||||
INSERT INTO t3(a) VALUES (3);
|
||||
|
||||
INSERT INTO t4(a,b,c) VALUES (1, null, 1);
|
||||
INSERT INTO t4(a,b,c) VALUES (2,'1111-11-11', 2);
|
||||
INSERT INTO t4(a,b) VALUES (3, null);
|
||||
INSERT INTO t4(a,c) VALUES (4, 4);
|
||||
INSERT INTO t4(a) VALUES (5);
|
||||
|
||||
--echo ************* SHOWING THE RESULT SETS WITH INSERTS *************
|
||||
sync_slave_with_master;
|
||||
|
||||
--echo TABLES t1 and t2 must be equal otherwise an error will be thrown.
|
||||
let $diff_table_1=master:test.t1;
|
||||
let $diff_table_2=slave:test.t1;
|
||||
source include/diff_tables.inc;
|
||||
|
||||
let $diff_table_1=master:test.t2;
|
||||
let $diff_table_2=slave:test.t2;
|
||||
source include/diff_tables.inc;
|
||||
|
||||
--echo TABLES t2 and t3 must be different.
|
||||
connection master;
|
||||
SELECT * FROM t3 ORDER BY a;
|
||||
connection slave;
|
||||
SELECT * FROM t3 ORDER BY a;
|
||||
connection master;
|
||||
SELECT * FROM t4 ORDER BY a;
|
||||
connection slave;
|
||||
SELECT * FROM t4 ORDER BY a;
|
||||
|
||||
--echo ************* EXECUTION WITH UPDATES and REPLACES *************
|
||||
connection master;
|
||||
DELETE FROM t1;
|
||||
INSERT INTO t1(a,b,c) VALUES (1,'1111-11-11', 1);
|
||||
REPLACE INTO t1(a,b,c) VALUES (2,'1111-11-11', 2);
|
||||
UPDATE t1 set b= NULL, c= 300 where a= 1;
|
||||
REPLACE INTO t1(a,b,c) VALUES (2, NULL, 300);
|
||||
|
||||
--echo ************* SHOWING THE RESULT SETS WITH UPDATES and REPLACES *************
|
||||
sync_slave_with_master;
|
||||
|
||||
--echo TABLES t1 and t2 must be equal otherwise an error will be thrown.
|
||||
let $diff_table_1=master:test.t1;
|
||||
let $diff_table_2=slave:test.t1;
|
||||
source include/diff_tables.inc;
|
||||
|
||||
--echo ************* CLEANING *************
|
||||
connection master;
|
||||
|
||||
DROP TABLE t1;
|
||||
DROP TABLE t2;
|
||||
DROP TABLE t3;
|
||||
DROP TABLE t4;
|
||||
|
||||
sync_slave_with_master;
|
||||
|
||||
connection master;
|
||||
|
||||
SET SQL_LOG_BIN= 0;
|
||||
eval CREATE TABLE t1 (`a` INT, `b` BIT DEFAULT NULL, `c` BIT DEFAULT NULL,
|
||||
PRIMARY KEY (`a`)) ENGINE= $engine;
|
||||
SET SQL_LOG_BIN= 1;
|
||||
|
||||
connection slave;
|
||||
|
||||
eval CREATE TABLE t1 (`a` INT, `b` BIT DEFAULT b'01', `c` BIT DEFAULT NULL,
|
||||
PRIMARY KEY (`a`)) ENGINE= $engine;
|
||||
|
||||
--echo ************* EXECUTION WITH INSERTS *************
|
||||
connection master;
|
||||
INSERT INTO t1(a,b,c) VALUES (1, null, b'01');
|
||||
INSERT INTO t1(a,b,c) VALUES (2,b'00', b'01');
|
||||
INSERT INTO t1(a,b) VALUES (3, null);
|
||||
INSERT INTO t1(a,c) VALUES (4, b'01');
|
||||
INSERT INTO t1(a) VALUES (5);
|
||||
|
||||
--echo ************* SHOWING THE RESULT SETS WITH INSERTS *************
|
||||
--echo TABLES t1 and t2 must be different.
|
||||
sync_slave_with_master;
|
||||
connection master;
|
||||
SELECT a,b+0,c+0 FROM t1 ORDER BY a;
|
||||
connection slave;
|
||||
SELECT a,b+0,c+0 FROM t1 ORDER BY a;
|
||||
|
||||
--echo ************* EXECUTION WITH UPDATES and REPLACES *************
|
||||
connection master;
|
||||
DELETE FROM t1;
|
||||
INSERT INTO t1(a,b,c) VALUES (1,b'00', b'01');
|
||||
REPLACE INTO t1(a,b,c) VALUES (2,b'00',b'01');
|
||||
UPDATE t1 set b= NULL, c= b'00' where a= 1;
|
||||
REPLACE INTO t1(a,b,c) VALUES (2, NULL, b'00');
|
||||
|
||||
--echo ************* SHOWING THE RESULT SETS WITH UPDATES and REPLACES *************
|
||||
--echo TABLES t1 and t2 must be equal otherwise an error will be thrown.
|
||||
sync_slave_with_master;
|
||||
let $diff_table_1=master:test.t1;
|
||||
let $diff_table_2=slave:test.t1;
|
||||
source include/diff_tables.inc;
|
||||
|
||||
connection master;
|
||||
|
||||
DROP TABLE t1;
|
||||
|
||||
sync_slave_with_master;
|
||||
|
||||
--echo ################################################################################
|
||||
--echo # NULL ---> NOT NULL (STRICT MODE)
|
||||
--echo # UNCOMMENT THIS AFTER FIXING BUG#43992
|
||||
--echo ################################################################################
|
||||
#connection slave;
|
||||
#SET GLOBAL sql_mode="TRADITIONAL";
|
||||
#
|
||||
#STOP SLAVE;
|
||||
#--source include/wait_for_slave_to_stop.inc
|
||||
#START SLAVE;
|
||||
#--source include/wait_for_slave_to_start.inc
|
||||
#
|
||||
#let $y=0;
|
||||
#while (`select $y < 6`)
|
||||
#{
|
||||
# connection master;
|
||||
#
|
||||
# SET SQL_LOG_BIN= 0;
|
||||
# eval CREATE TABLE t1(`a` INT NOT NULL, `b` INT,
|
||||
# PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
# eval CREATE TABLE t2(`a` INT NOT NULL, `b` INT,
|
||||
# PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
# eval CREATE TABLE t3(`a` INT NOT NULL, `b` INT,
|
||||
# PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
# SET SQL_LOG_BIN= 1;
|
||||
#
|
||||
# connection slave;
|
||||
#
|
||||
# eval CREATE TABLE t1(`a` INT NOT NULL, `b` INT NOT NULL,
|
||||
# `c` INT NOT NULL,
|
||||
# PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
# eval CREATE TABLE t2(`a` INT NOT NULL, `b` INT NOT NULL,
|
||||
# `c` INT,
|
||||
# PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
# eval CREATE TABLE t3(`a` INT NOT NULL, `b` INT NOT NULL,
|
||||
# `c` INT DEFAULT 500,
|
||||
# PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
#
|
||||
# if (`select $y=0`)
|
||||
# {
|
||||
# --echo ************* EXECUTION WITH INSERTS *************
|
||||
# connection master;
|
||||
# INSERT INTO t1(a) VALUES (1);
|
||||
# }
|
||||
#
|
||||
# if (`select $y=1`)
|
||||
# {
|
||||
# --echo ************* EXECUTION WITH INSERTS *************
|
||||
# connection master;
|
||||
# INSERT INTO t1(a, b) VALUES (1, NULL);
|
||||
# }
|
||||
#
|
||||
# if (`select $y=2`)
|
||||
# {
|
||||
# --echo ************* EXECUTION WITH UPDATES *************
|
||||
# connection master;
|
||||
# INSERT INTO t3(a, b) VALUES (1, 1);
|
||||
# INSERT INTO t3(a, b) VALUES (2, 1);
|
||||
# UPDATE t3 SET b = NULL where a= 1;
|
||||
# }
|
||||
#
|
||||
# if (`select $y=3`)
|
||||
# {
|
||||
# --echo ************* EXECUTION WITH INSERTS/REPLACES *************
|
||||
# connection master;
|
||||
# REPLACE INTO t3(a, b) VALUES (1, null);
|
||||
# }
|
||||
#
|
||||
# if (`select $y=4`)
|
||||
# {
|
||||
# --echo ************* EXECUTION WITH UPDATES/REPLACES *************
|
||||
# connection master;
|
||||
# INSERT INTO t3(a, b) VALUES (1, 1);
|
||||
# REPLACE INTO t3(a, b) VALUES (1, null);
|
||||
# }
|
||||
#
|
||||
# if (`select $y=5`)
|
||||
# {
|
||||
# --echo ************* EXECUTION WITH MULTI-ROW INSERTS *************
|
||||
# connection master;
|
||||
#
|
||||
# SET SQL_LOG_BIN= 0;
|
||||
# INSERT INTO t2(a, b) VALUES (1, 1);
|
||||
# INSERT INTO t2(a, b) VALUES (2, 1);
|
||||
# INSERT INTO t2(a, b) VALUES (3, null);
|
||||
# INSERT INTO t2(a, b) VALUES (4, 1);
|
||||
# INSERT INTO t2(a, b) VALUES (5, 1);
|
||||
# SET SQL_LOG_BIN= 1;
|
||||
#
|
||||
# INSERT INTO t2 SELECT a + 10, b from t2;
|
||||
# --echo The statement below is just executed to stop processing
|
||||
# INSERT INTO t1(a) VALUES (1);
|
||||
# }
|
||||
#
|
||||
# --echo ************* SHOWING THE RESULT SETS *************
|
||||
# connection slave;
|
||||
# --source include/wait_for_slave_sql_to_stop.inc
|
||||
# connection master;
|
||||
# SELECT * FROM t1 ORDER BY a;
|
||||
# connection slave;
|
||||
# SELECT * FROM t1 ORDER BY a;
|
||||
# connection master;
|
||||
# SELECT * FROM t2 ORDER BY a;
|
||||
# connection slave;
|
||||
# SELECT * FROM t2 ORDER BY a;
|
||||
# connection master;
|
||||
# SELECT * FROM t3 ORDER BY a;
|
||||
# connection slave;
|
||||
# SELECT * FROM t3 ORDER BY a;
|
||||
# --source include/reset_master_and_slave.inc
|
||||
#
|
||||
# connection master;
|
||||
#
|
||||
# DROP TABLE t1;
|
||||
# DROP TABLE t2;
|
||||
# DROP TABLE t3;
|
||||
#
|
||||
# sync_slave_with_master;
|
||||
#
|
||||
# inc $y;
|
||||
#}
|
||||
#connection slave;
|
||||
#SET GLOBAL sql_mode="";
|
||||
#
|
||||
#STOP SLAVE;
|
||||
#source include/wait_for_slave_to_stop.inc;
|
||||
#START SLAVE;
|
||||
#--source include/wait_for_slave_to_start.inc
|
||||
|
||||
--echo ################################################################################
|
||||
--echo # NULL ---> NOT NULL (NON-STRICT MODE)
|
||||
--echo ################################################################################
|
||||
connection master;
|
||||
|
||||
SET SQL_LOG_BIN= 0;
|
||||
eval CREATE TABLE t1(`a` INT NOT NULL, `b` INT,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
eval CREATE TABLE t2(`a` INT NOT NULL, `b` INT,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
eval CREATE TABLE t3(`a` INT NOT NULL, `b` INT,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
SET SQL_LOG_BIN= 1;
|
||||
|
||||
connection slave;
|
||||
|
||||
eval CREATE TABLE t1(`a` INT NOT NULL, `b` INT NOT NULL,
|
||||
`c` INT NOT NULL,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
eval CREATE TABLE t2(`a` INT NOT NULL, `b` INT NOT NULL,
|
||||
`c` INT,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
eval CREATE TABLE t3(`a` INT NOT NULL, `b` INT NOT NULL,
|
||||
`c` INT DEFAULT 500,
|
||||
PRIMARY KEY(`a`)) ENGINE=$engine DEFAULT CHARSET=LATIN1;
|
||||
|
||||
--echo ************* EXECUTION WITH INSERTS *************
|
||||
connection master;
|
||||
INSERT INTO t1(a) VALUES (1);
|
||||
INSERT INTO t1(a, b) VALUES (2, NULL);
|
||||
INSERT INTO t1(a, b) VALUES (3, 1);
|
||||
|
||||
INSERT INTO t2(a) VALUES (1);
|
||||
INSERT INTO t2(a, b) VALUES (2, NULL);
|
||||
INSERT INTO t2(a, b) VALUES (3, 1);
|
||||
|
||||
INSERT INTO t3(a) VALUES (1);
|
||||
INSERT INTO t3(a, b) VALUES (2, NULL);
|
||||
INSERT INTO t3(a, b) VALUES (3, 1);
|
||||
INSERT INTO t3(a, b) VALUES (4, 1);
|
||||
REPLACE INTO t3(a, b) VALUES (5, null);
|
||||
|
||||
REPLACE INTO t3(a, b) VALUES (3, null);
|
||||
UPDATE t3 SET b = NULL where a = 4;
|
||||
|
||||
--echo ************* SHOWING THE RESULT SETS *************
|
||||
connection master;
|
||||
sync_slave_with_master;
|
||||
|
||||
connection master;
|
||||
SELECT * FROM t1 ORDER BY a;
|
||||
connection slave;
|
||||
SELECT * FROM t1 ORDER BY a;
|
||||
connection master;
|
||||
SELECT * FROM t2 ORDER BY a;
|
||||
connection slave;
|
||||
SELECT * FROM t2 ORDER BY a;
|
||||
connection master;
|
||||
SELECT * FROM t3 ORDER BY a;
|
||||
connection slave;
|
||||
SELECT * FROM t3 ORDER BY a;
|
||||
|
||||
connection master;
|
||||
|
||||
DROP TABLE t1;
|
||||
DROP TABLE t2;
|
||||
DROP TABLE t3;
|
||||
|
||||
sync_slave_with_master;
|
|
@ -111,21 +111,18 @@ SELECT a,b,x FROM t1_int ORDER BY a;
|
|||
SELECT a,b,HEX(x),HEX(y),HEX(z) FROM t1_bit ORDER BY a;
|
||||
SELECT a,b,x FROM t1_char ORDER BY a;
|
||||
|
||||
# Each of these inserts should generate an error and stop the slave
|
||||
|
||||
connection master;
|
||||
INSERT INTO t9 VALUES (2);
|
||||
sync_slave_with_master;
|
||||
# Now slave is guaranteed to be running
|
||||
connection master;
|
||||
INSERT INTO t1_nodef VALUES (1,2);
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 20 <Last_Error> 22 # 23 # 33 # 35 <Last_IO_Errno> 36 <Last_IO_Error> 38 <Last_SQL_Error>
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
|
||||
# Last insert on wider slave table succeeds while slave sql sql_mode permits.
|
||||
# The previous version of the above test expected slave sql to stop.
|
||||
# bug#38173 relaxed conditions to stop only with the strict mode.
|
||||
sync_slave_with_master;
|
||||
select count(*) from t1_nodef;
|
||||
|
||||
#
|
||||
# Replicating to tables with fewer columns at the end works as of WL#3228
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
-- source include/have_binlog_format_mixed_or_statement.inc
|
||||
# Requires binlog_format=statement format since query involving
|
||||
# get_lock() is logged in row format if binlog_format=mixed or row.
|
||||
-- source include/have_binlog_format_statement.inc
|
||||
-- source include/master-slave.inc
|
||||
|
||||
CALL mtr.add_suppression("Statement may not be safe to log in statement format.");
|
||||
|
||||
# Load some data into t1
|
||||
create table t1 (word char(20) not null);
|
||||
load data infile '../../std_data/words.dat' into table t1;
|
||||
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
||||
|
@ -10,9 +15,7 @@ select * from t1 limit 10;
|
|||
#
|
||||
# Test slave with wrong password
|
||||
#
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
sync_slave_with_master;
|
||||
stop slave;
|
||||
connection master;
|
||||
set password for root@"localhost" = password('foo');
|
||||
|
@ -29,16 +32,12 @@ sleep 2;
|
|||
|
||||
create table t3(n int);
|
||||
insert into t3 values(1),(2);
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
sync_slave_with_master;
|
||||
select * from t3;
|
||||
select sum(length(word)) from t1;
|
||||
connection master;
|
||||
drop table t1,t3;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
sync_slave_with_master;
|
||||
|
||||
# Test if the slave SQL thread can be more than 16K behind the slave
|
||||
# I/O thread (> IO_SIZE)
|
||||
|
@ -77,12 +76,13 @@ unlock tables;
|
|||
connection master;
|
||||
create table t2(id int);
|
||||
insert into t2 values(connection_id());
|
||||
save_master_pos;
|
||||
|
||||
connection master1;
|
||||
# Avoid generating result
|
||||
create temporary table t3(n int);
|
||||
--disable_warnings
|
||||
insert into t3 select get_lock('crash_lock%20C', 1) from t2;
|
||||
--enable_warnings
|
||||
|
||||
connection master;
|
||||
send update t1 set n = n + get_lock('crash_lock%20C', 2);
|
||||
|
@ -93,8 +93,11 @@ kill @id;
|
|||
# We don't drop t3 as this is a temporary table
|
||||
drop table t2;
|
||||
connection master;
|
||||
# The get_lock function causes warning for unsafe statement.
|
||||
--disable_warnings
|
||||
--error 1317,2013
|
||||
reap;
|
||||
--enable_warnings
|
||||
connection slave;
|
||||
# The SQL slave thread should now have stopped because the query was killed on
|
||||
# the master (so it has a non-zero error code in the binlog).
|
||||
|
@ -117,16 +120,12 @@ insert into mysql.user (Host, User, Password)
|
|||
select select_priv,user from mysql.user where user = _binary'blafasel2';
|
||||
update mysql.user set Select_priv = "Y" where User= _binary"blafasel2";
|
||||
select select_priv,user from mysql.user where user = _binary'blafasel2';
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
sync_slave_with_master;
|
||||
select n from t1;
|
||||
select select_priv,user from mysql.user where user = _binary'blafasel2';
|
||||
connection master1;
|
||||
drop table t1;
|
||||
delete from mysql.user where user="blafasel2";
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
sync_slave_with_master;
|
||||
|
||||
# End of 4.1 tests
|
||||
|
|
|
@ -175,6 +175,8 @@ INSERT INTO global_suppressions VALUES
|
|||
("Can't find file: '.\\\\test\\\\\\?{8}.frm'"),
|
||||
("Slave: Unknown table 't1' Error_code: 1051"),
|
||||
|
||||
/* Maria storage engine dependent tests */
|
||||
|
||||
/* maria-recovery.test has warning about missing log file */
|
||||
("File '.*maria_log.000.*' not found \\(Errcode: 2\\)"),
|
||||
/* and about marked-corrupted table */
|
||||
|
@ -184,6 +186,14 @@ INSERT INTO global_suppressions VALUES
|
|||
("Table '..mysqltest.t_corrupted2' is marked as crashed and should be"),
|
||||
("Incorrect key file for table '..mysqltest.t_corrupted2.MAI'"),
|
||||
|
||||
/*
|
||||
Transient network failures that cause warnings on reconnect.
|
||||
BUG#47743 and BUG#47983.
|
||||
*/
|
||||
("Slave I/O: Get master SERVER_ID failed with error:.*"),
|
||||
("Slave I/O: Get master clock failed with error:.*"),
|
||||
("Slave I/O: Get master COLLATION_SERVER failed with error:.*"),
|
||||
("Slave I/O: Get master TIME_ZONE failed with error:.*"),
|
||||
|
||||
("THE_LAST_SUPPRESSION")||
|
||||
|
||||
|
|
|
@ -30,6 +30,9 @@
|
|||
--disable_warnings
|
||||
drop table if exists t5 ;
|
||||
--enable_warnings
|
||||
--disable_query_log
|
||||
SET TIME_ZONE= '+03:00';
|
||||
--enable_query_log
|
||||
set @arg01= 8;
|
||||
set @arg02= 8.0;
|
||||
set @arg03= 80.00000000000e-1;
|
||||
|
|
|
@ -524,6 +524,10 @@ sub collect_one_suite
|
|||
next if ($test->{'name'} eq 'sys_vars.innodb_thread_concurrency_basic');
|
||||
# Can't work with InnoPlug. Test framework needs to be re-designed.
|
||||
next if ($test->{'name'} eq 'main.innodb_bug46000');
|
||||
# Fails with innodb plugin
|
||||
next if ($test->{'name'} eq 'main.innodb-autoinc');
|
||||
# Fails with innodb plugin: r6185 Testcases changes not included
|
||||
next if ($test->{'name'} eq 'main.innodb_bug44369');
|
||||
# Copy test options
|
||||
my $new_test= My::Test->new();
|
||||
while (my ($key, $value) = each(%$test))
|
||||
|
|
|
@ -301,6 +301,9 @@ sub main {
|
|||
}
|
||||
}
|
||||
|
||||
# Check for plugin availability so we know whether to skip tests or not.
|
||||
detect_plugins();
|
||||
|
||||
mtr_report("Collecting tests...");
|
||||
my $tests= collect_test_cases($opt_suites, \@opt_cases);
|
||||
|
||||
|
@ -410,7 +413,6 @@ sub main {
|
|||
# Not all tests completed, failure
|
||||
mtr_report();
|
||||
mtr_report("Only ", int(@$completed), " of $num_tests completed.");
|
||||
mtr_error("Not all tests completed");
|
||||
}
|
||||
|
||||
mtr_print_line();
|
||||
|
@ -422,6 +424,10 @@ sub main {
|
|||
|
||||
mtr_report_stats($fail, $completed, $extra_warnings);
|
||||
|
||||
if ( @$completed != $num_tests)
|
||||
{
|
||||
mtr_error("Not all tests completed");
|
||||
}
|
||||
exit(0);
|
||||
}
|
||||
|
||||
|
@ -1877,6 +1883,37 @@ sub have_maria_support () {
|
|||
}
|
||||
|
||||
|
||||
# Detect plugin presense and set environment variables appropriately.
|
||||
# This needs to be done early, so we can know whether to skip tests.
|
||||
sub detect_plugins {
|
||||
# --------------------------------------------------------------------------
|
||||
# Add the path where mysqld will find ha_example.so
|
||||
# --------------------------------------------------------------------------
|
||||
if ($mysql_version_id >= 50100) {
|
||||
my $plugin_filename;
|
||||
if (IS_WINDOWS)
|
||||
{
|
||||
$plugin_filename = "ha_example.dll";
|
||||
}
|
||||
else
|
||||
{
|
||||
$plugin_filename = "ha_example.so";
|
||||
}
|
||||
my $lib_example_plugin=
|
||||
mtr_file_exists(vs_config_dirs('storage/example',$plugin_filename),
|
||||
"$basedir/storage/example/.libs/".$plugin_filename,
|
||||
"$basedir/lib/mariadb/plugin/".$plugin_filename,
|
||||
"$basedir/lib/mysql/plugin/".$plugin_filename);
|
||||
$ENV{'EXAMPLE_PLUGIN'}=
|
||||
($lib_example_plugin ? basename($lib_example_plugin) : "");
|
||||
$ENV{'EXAMPLE_PLUGIN_OPT'}= "--plugin-dir=".
|
||||
($lib_example_plugin ? dirname($lib_example_plugin) : "");
|
||||
|
||||
$ENV{'HA_EXAMPLE_SO'}="'".$plugin_filename."'";
|
||||
$ENV{'EXAMPLE_PLUGIN_LOAD'}="--plugin_load=EXAMPLE=".$plugin_filename;
|
||||
}
|
||||
}
|
||||
|
||||
#
|
||||
# Set environment to be used by childs of this process for
|
||||
# things that are constant during the whole lifetime of mysql-test-run
|
||||
|
@ -1935,33 +1972,6 @@ sub environment_setup {
|
|||
$ENV{'UDF_EXAMPLE_LIB_OPT'}= "--plugin-dir=".
|
||||
($lib_udf_example ? dirname($lib_udf_example) : "");
|
||||
|
||||
# --------------------------------------------------------------------------
|
||||
# Add the path where mysqld will find ha_example.so
|
||||
# --------------------------------------------------------------------------
|
||||
if ($mysql_version_id >= 50100) {
|
||||
my $plugin_filename;
|
||||
if (IS_WINDOWS)
|
||||
{
|
||||
$plugin_filename = "ha_example.dll";
|
||||
}
|
||||
else
|
||||
{
|
||||
$plugin_filename = "ha_example.so";
|
||||
}
|
||||
my $lib_example_plugin=
|
||||
mtr_file_exists(vs_config_dirs('storage/example',$plugin_filename),
|
||||
"$basedir/storage/example/.libs/".$plugin_filename,
|
||||
"$basedir/lib/mariadb/plugin/".$plugin_filename,
|
||||
"$basedir/lib/mysql/plugin/".$plugin_filename);
|
||||
$ENV{'EXAMPLE_PLUGIN'}=
|
||||
($lib_example_plugin ? basename($lib_example_plugin) : "");
|
||||
$ENV{'EXAMPLE_PLUGIN_OPT'}= "--plugin-dir=".
|
||||
($lib_example_plugin ? dirname($lib_example_plugin) : "");
|
||||
|
||||
$ENV{'HA_EXAMPLE_SO'}="'".$plugin_filename."'";
|
||||
$ENV{'EXAMPLE_PLUGIN_LOAD'}="--plugin_load=EXAMPLE=".$plugin_filename;
|
||||
}
|
||||
|
||||
# ----------------------------------------------------
|
||||
# Add the path where mysqld will find mypluglib.so
|
||||
# ----------------------------------------------------
|
||||
|
@ -3418,7 +3428,7 @@ sub restart_forced_by_test
|
|||
# Return timezone value of tinfo or default value
|
||||
sub timezone {
|
||||
my ($tinfo)= @_;
|
||||
return $tinfo->{timezone} || "GMT-3";
|
||||
return $tinfo->{timezone} || "DEFAULT";
|
||||
}
|
||||
|
||||
|
||||
|
@ -3448,7 +3458,11 @@ sub run_testcase ($$) {
|
|||
# Init variables that can change between each test case
|
||||
# -------------------------------------------------------
|
||||
my $timezone= timezone($tinfo);
|
||||
if ($timezone ne 'DEFAULT') {
|
||||
$ENV{'TZ'}= $timezone;
|
||||
} else {
|
||||
delete($ENV{'TZ'});
|
||||
}
|
||||
mtr_verbose("Setting timezone: $timezone");
|
||||
|
||||
if ( ! using_extern() )
|
||||
|
@ -4003,6 +4017,7 @@ sub extract_warning_lines ($) {
|
|||
qr/Slave I\/O: error reconnecting to master '.*' - retry-time: [1-3] retries/,
|
||||
qr/Error reading packet/,
|
||||
qr/Slave: Can't drop database.* database doesn't exist/,
|
||||
qr/Slave: Operation DROP USER failed for 'create_rout_db'/,
|
||||
);
|
||||
|
||||
my $matched_lines= [];
|
||||
|
|
|
@ -12717,3 +12717,14 @@ COUNT(t1.a)
|
|||
729
|
||||
DROP TABLE t1;
|
||||
SET @@join_buffer_size= @save_join_buffer_size;
|
||||
SHOW CREATE TABLE t1;
|
||||
ERROR HY000: Table upgrade required. Please do "REPAIR TABLE `t1`" or dump/reload to fix it!
|
||||
SELECT * FROM t1;
|
||||
ERROR HY000: Table upgrade required. Please do "REPAIR TABLE `t1`" or dump/reload to fix it!
|
||||
INSERT INTO t1 (col1, col2) VALUES (1, "value");
|
||||
ERROR HY000: Table upgrade required. Please do "REPAIR TABLE `t1`" or dump/reload to fix it!
|
||||
REPAIR TABLE t1;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 repair Error Table upgrade required. Please do "REPAIR TABLE `t1`" or dump/reload to fix it!
|
||||
test.t1 repair error Corrupt
|
||||
DROP TABLE t1;
|
||||
|
|
14
mysql-test/r/bug47671.result
Normal file
14
mysql-test/r/bug47671.result
Normal file
|
@ -0,0 +1,14 @@
|
|||
#
|
||||
# Bug#47671 - wrong character-set after upgrade from 5.1.34 to 5.1.39
|
||||
#
|
||||
# Extract only charset information from 'status' command output using regex
|
||||
--------------
|
||||
|
||||
Server: MariaDB
|
||||
Server characterset: utf8
|
||||
Db characterset: utf8
|
||||
Client characterset: utf8
|
||||
Conn. characterset: utf8
|
||||
|
||||
--------------
|
||||
|
|
@ -314,4 +314,16 @@ a b
|
|||
2 2
|
||||
drop table t1;
|
||||
set global low_priority_updates = @old_delayed_updates;
|
||||
#
|
||||
# Bug #47682 strange behaviour of INSERT DELAYED
|
||||
#
|
||||
DROP TABLE IF EXISTS t1, t2;
|
||||
CREATE TABLE t1 (f1 integer);
|
||||
CREATE TABLE t2 (f1 integer);
|
||||
FLUSH TABLES WITH READ LOCK;
|
||||
LOCK TABLES t1 READ;
|
||||
INSERT DELAYED INTO t2 VALUES (1);
|
||||
Got one of the listed errors
|
||||
UNLOCK TABLES;
|
||||
DROP TABLE t1, t2;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -324,3 +324,16 @@ a
|
|||
1
|
||||
2
|
||||
DROP TABLE t1, t2, t3;
|
||||
#
|
||||
# Bug #46425 crash in Diagnostics_area::set_ok_status,
|
||||
# empty statement, DELETE IGNORE
|
||||
#
|
||||
CREATE table t1 (i INTEGER);
|
||||
INSERT INTO t1 VALUES (1);
|
||||
CREATE TRIGGER tr1 AFTER DELETE ON t1 FOR EACH ROW
|
||||
BEGIN
|
||||
INSERT INTO t1 SELECT * FROM t1 AS A;
|
||||
END |
|
||||
DELETE IGNORE FROM t1;
|
||||
ERROR HY000: Can't update table 't1' in stored function/trigger because it is already used by statement which invoked this stored function/trigger.
|
||||
DROP TABLE t1;
|
||||
|
|
|
@ -559,3 +559,42 @@ EXECUTE s;
|
|||
MATCH (col) AGAINST('findme')
|
||||
DEALLOCATE PREPARE s;
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug #47930: MATCH IN BOOLEAN MODE returns too many results
|
||||
# inside subquery
|
||||
#
|
||||
CREATE TABLE t1 (a int);
|
||||
INSERT INTO t1 VALUES (1), (2);
|
||||
CREATE TABLE t2 (a int, b2 char(10), FULLTEXT KEY b2 (b2));
|
||||
INSERT INTO t2 VALUES (1,'Scargill');
|
||||
CREATE TABLE t3 (a int, b int);
|
||||
INSERT INTO t3 VALUES (1,1), (2,1);
|
||||
# t2 should use full text index
|
||||
EXPLAIN
|
||||
SELECT count(*) FROM t1 WHERE
|
||||
not exists(
|
||||
SELECT 1 FROM t2, t3
|
||||
WHERE t3.a=t1.a AND MATCH(b2) AGAINST('scargill' IN BOOLEAN MODE)
|
||||
);
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 PRIMARY t1 ALL NULL NULL NULL NULL 2 Using where
|
||||
2 DEPENDENT SUBQUERY t2 fulltext b2 b2 0 1 Using where
|
||||
2 DEPENDENT SUBQUERY t3 ALL NULL NULL NULL NULL 2 Using where
|
||||
# should return 0
|
||||
SELECT count(*) FROM t1 WHERE
|
||||
not exists(
|
||||
SELECT 1 FROM t2, t3
|
||||
WHERE t3.a=t1.a AND MATCH(b2) AGAINST('scargill' IN BOOLEAN MODE)
|
||||
);
|
||||
count(*)
|
||||
0
|
||||
# should return 0
|
||||
SELECT count(*) FROM t1 WHERE
|
||||
not exists(
|
||||
SELECT 1 FROM t2 IGNORE INDEX (b2), t3
|
||||
WHERE t3.a=t1.a AND MATCH(b2) AGAINST('scargill' IN BOOLEAN MODE)
|
||||
);
|
||||
count(*)
|
||||
0
|
||||
DROP TABLE t1,t2,t3;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -885,7 +885,7 @@ cast(sum(distinct df) as signed)
|
|||
3
|
||||
select cast(min(df) as signed) from t1;
|
||||
cast(min(df) as signed)
|
||||
0
|
||||
1
|
||||
select 1e8 * sum(distinct df) from t1;
|
||||
1e8 * sum(distinct df)
|
||||
330000000
|
||||
|
@ -1520,4 +1520,197 @@ max i
|
|||
# Cleanup
|
||||
#
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug#43668: Wrong comparison and MIN/MAX for YEAR(2)
|
||||
#
|
||||
create table t1 (f1 year(2), f2 year(4), f3 date, f4 datetime);
|
||||
insert into t1 values
|
||||
(98,1998,19980101,"1998-01-01 00:00:00"),
|
||||
(00,2000,20000101,"2000-01-01 00:00:01"),
|
||||
(02,2002,20020101,"2002-01-01 23:59:59"),
|
||||
(60,2060,20600101,"2060-01-01 11:11:11"),
|
||||
(70,1970,19700101,"1970-11-11 22:22:22"),
|
||||
(NULL,NULL,NULL,NULL);
|
||||
select min(f1),max(f1) from t1;
|
||||
min(f1) max(f1)
|
||||
70 60
|
||||
select min(f2),max(f2) from t1;
|
||||
min(f2) max(f2)
|
||||
1970 2060
|
||||
select min(f3),max(f3) from t1;
|
||||
min(f3) max(f3)
|
||||
1970-01-01 2060-01-01
|
||||
select min(f4),max(f4) from t1;
|
||||
min(f4) max(f4)
|
||||
1970-11-11 22:22:22 2060-01-01 11:11:11
|
||||
select a.f1 as a, b.f1 as b, a.f1 > b.f1 as gt,
|
||||
a.f1 < b.f1 as lt, a.f1<=>b.f1 as eq
|
||||
from t1 a, t1 b;
|
||||
a b gt lt eq
|
||||
98 98 0 0 1
|
||||
00 98 1 0 0
|
||||
02 98 1 0 0
|
||||
60 98 1 0 0
|
||||
70 98 0 1 0
|
||||
NULL 98 NULL NULL 0
|
||||
98 00 0 1 0
|
||||
00 00 0 0 1
|
||||
02 00 1 0 0
|
||||
60 00 1 0 0
|
||||
70 00 0 1 0
|
||||
NULL 00 NULL NULL 0
|
||||
98 02 0 1 0
|
||||
00 02 0 1 0
|
||||
02 02 0 0 1
|
||||
60 02 1 0 0
|
||||
70 02 0 1 0
|
||||
NULL 02 NULL NULL 0
|
||||
98 60 0 1 0
|
||||
00 60 0 1 0
|
||||
02 60 0 1 0
|
||||
60 60 0 0 1
|
||||
70 60 0 1 0
|
||||
NULL 60 NULL NULL 0
|
||||
98 70 1 0 0
|
||||
00 70 1 0 0
|
||||
02 70 1 0 0
|
||||
60 70 1 0 0
|
||||
70 70 0 0 1
|
||||
NULL 70 NULL NULL 0
|
||||
98 NULL NULL NULL 0
|
||||
00 NULL NULL NULL 0
|
||||
02 NULL NULL NULL 0
|
||||
60 NULL NULL NULL 0
|
||||
70 NULL NULL NULL 0
|
||||
NULL NULL NULL NULL 1
|
||||
select a.f1 as a, b.f2 as b, a.f1 > b.f2 as gt,
|
||||
a.f1 < b.f2 as lt, a.f1<=>b.f2 as eq
|
||||
from t1 a, t1 b;
|
||||
a b gt lt eq
|
||||
98 1998 0 0 1
|
||||
00 1998 1 0 0
|
||||
02 1998 1 0 0
|
||||
60 1998 1 0 0
|
||||
70 1998 0 1 0
|
||||
NULL 1998 NULL NULL 0
|
||||
98 2000 0 1 0
|
||||
00 2000 0 0 1
|
||||
02 2000 1 0 0
|
||||
60 2000 1 0 0
|
||||
70 2000 0 1 0
|
||||
NULL 2000 NULL NULL 0
|
||||
98 2002 0 1 0
|
||||
00 2002 0 1 0
|
||||
02 2002 0 0 1
|
||||
60 2002 1 0 0
|
||||
70 2002 0 1 0
|
||||
NULL 2002 NULL NULL 0
|
||||
98 2060 0 1 0
|
||||
00 2060 0 1 0
|
||||
02 2060 0 1 0
|
||||
60 2060 0 0 1
|
||||
70 2060 0 1 0
|
||||
NULL 2060 NULL NULL 0
|
||||
98 1970 1 0 0
|
||||
00 1970 1 0 0
|
||||
02 1970 1 0 0
|
||||
60 1970 1 0 0
|
||||
70 1970 0 0 1
|
||||
NULL 1970 NULL NULL 0
|
||||
98 NULL NULL NULL 0
|
||||
00 NULL NULL NULL 0
|
||||
02 NULL NULL NULL 0
|
||||
60 NULL NULL NULL 0
|
||||
70 NULL NULL NULL 0
|
||||
NULL NULL NULL NULL 1
|
||||
select a.f1 as a, b.f3 as b, a.f1 > b.f3 as gt,
|
||||
a.f1 < b.f3 as lt, a.f1<=>b.f3 as eq
|
||||
from t1 a, t1 b;
|
||||
a b gt lt eq
|
||||
98 1998-01-01 0 1 0
|
||||
00 1998-01-01 1 0 0
|
||||
02 1998-01-01 1 0 0
|
||||
60 1998-01-01 1 0 0
|
||||
70 1998-01-01 0 1 0
|
||||
NULL 1998-01-01 NULL NULL 0
|
||||
98 2000-01-01 0 1 0
|
||||
00 2000-01-01 0 1 0
|
||||
02 2000-01-01 1 0 0
|
||||
60 2000-01-01 1 0 0
|
||||
70 2000-01-01 0 1 0
|
||||
NULL 2000-01-01 NULL NULL 0
|
||||
98 2002-01-01 0 1 0
|
||||
00 2002-01-01 0 1 0
|
||||
02 2002-01-01 0 1 0
|
||||
60 2002-01-01 1 0 0
|
||||
70 2002-01-01 0 1 0
|
||||
NULL 2002-01-01 NULL NULL 0
|
||||
98 2060-01-01 0 1 0
|
||||
00 2060-01-01 0 1 0
|
||||
02 2060-01-01 0 1 0
|
||||
60 2060-01-01 0 1 0
|
||||
70 2060-01-01 0 1 0
|
||||
NULL 2060-01-01 NULL NULL 0
|
||||
98 1970-01-01 1 0 0
|
||||
00 1970-01-01 1 0 0
|
||||
02 1970-01-01 1 0 0
|
||||
60 1970-01-01 1 0 0
|
||||
70 1970-01-01 0 1 0
|
||||
NULL 1970-01-01 NULL NULL 0
|
||||
98 NULL NULL NULL 0
|
||||
00 NULL NULL NULL 0
|
||||
02 NULL NULL NULL 0
|
||||
60 NULL NULL NULL 0
|
||||
70 NULL NULL NULL 0
|
||||
NULL NULL NULL NULL 1
|
||||
select a.f1 as a, b.f4 as b, a.f1 > b.f4 as gt,
|
||||
a.f1 < b.f4 as lt, a.f1<=>b.f4 as eq
|
||||
from t1 a, t1 b;
|
||||
a b gt lt eq
|
||||
98 1998-01-01 00:00:00 0 1 0
|
||||
00 1998-01-01 00:00:00 1 0 0
|
||||
02 1998-01-01 00:00:00 1 0 0
|
||||
60 1998-01-01 00:00:00 1 0 0
|
||||
70 1998-01-01 00:00:00 0 1 0
|
||||
NULL 1998-01-01 00:00:00 NULL NULL 0
|
||||
98 2000-01-01 00:00:01 0 1 0
|
||||
00 2000-01-01 00:00:01 0 1 0
|
||||
02 2000-01-01 00:00:01 1 0 0
|
||||
60 2000-01-01 00:00:01 1 0 0
|
||||
70 2000-01-01 00:00:01 0 1 0
|
||||
NULL 2000-01-01 00:00:01 NULL NULL 0
|
||||
98 2002-01-01 23:59:59 0 1 0
|
||||
00 2002-01-01 23:59:59 0 1 0
|
||||
02 2002-01-01 23:59:59 0 1 0
|
||||
60 2002-01-01 23:59:59 1 0 0
|
||||
70 2002-01-01 23:59:59 0 1 0
|
||||
NULL 2002-01-01 23:59:59 NULL NULL 0
|
||||
98 2060-01-01 11:11:11 0 1 0
|
||||
00 2060-01-01 11:11:11 0 1 0
|
||||
02 2060-01-01 11:11:11 0 1 0
|
||||
60 2060-01-01 11:11:11 0 1 0
|
||||
70 2060-01-01 11:11:11 0 1 0
|
||||
NULL 2060-01-01 11:11:11 NULL NULL 0
|
||||
98 1970-11-11 22:22:22 1 0 0
|
||||
00 1970-11-11 22:22:22 1 0 0
|
||||
02 1970-11-11 22:22:22 1 0 0
|
||||
60 1970-11-11 22:22:22 1 0 0
|
||||
70 1970-11-11 22:22:22 0 1 0
|
||||
NULL 1970-11-11 22:22:22 NULL NULL 0
|
||||
98 NULL NULL NULL 0
|
||||
00 NULL NULL NULL 0
|
||||
02 NULL NULL NULL 0
|
||||
60 NULL NULL NULL 0
|
||||
70 NULL NULL NULL 0
|
||||
NULL NULL NULL NULL 1
|
||||
select *, f1 = f2 from t1;
|
||||
f1 f2 f3 f4 f1 = f2
|
||||
98 1998 1998-01-01 1998-01-01 00:00:00 1
|
||||
00 2000 2000-01-01 2000-01-01 00:00:01 1
|
||||
02 2002 2002-01-01 2002-01-01 23:59:59 1
|
||||
60 2060 2060-01-01 2060-01-01 11:11:11 1
|
||||
70 1970 1970-01-01 1970-11-11 22:22:22 1
|
||||
NULL NULL NULL NULL NULL
|
||||
drop table t1;
|
||||
#
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -104,95 +104,6 @@ t1 CREATE TABLE `t1` (
|
|||
`length(uuid())` int(10) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
#------------------------------------------------------------------------
|
||||
# Tests for Bug#6760 and Bug#12689
|
||||
SET @row_count = 4;
|
||||
SET @sleep_time_per_result_row = 1;
|
||||
SET @max_acceptable_delay = 2;
|
||||
SET @@global.query_cache_size = 1024 * 64;
|
||||
DROP TEMPORARY TABLE IF EXISTS t_history;
|
||||
DROP TABLE IF EXISTS t1;
|
||||
CREATE TEMPORARY TABLE t_history (attempt SMALLINT,
|
||||
start_ts DATETIME, end_ts DATETIME,
|
||||
start_cached INTEGER, end_cached INTEGER);
|
||||
CREATE TABLE t1 (f1 BIGINT);
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 4 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 4 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 4 + 1;
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 3 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 3 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 3 + 1;
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 2 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 2 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 2 + 1;
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 1 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 1 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 1 + 1;
|
||||
# Test 1: Does the query with SLEEP need a reasonable time?
|
||||
SELECT COUNT(*) >= 4 - 1 INTO @aux1 FROM t_history
|
||||
WHERE TIMEDIFF(end_ts,start_ts) - @sleep_time_per_result_row * @row_count
|
||||
BETWEEN 0 AND @max_acceptable_delay;
|
||||
SELECT @aux1 AS "Expect 1";
|
||||
Expect 1
|
||||
1
|
||||
# Test 2: Does the query with SLEEP need a reasonable time even in case
|
||||
# of the non first execution?
|
||||
SELECT COUNT(*) >= 4 - 1 - 1 INTO @aux2 FROM t_history
|
||||
WHERE TIMEDIFF(end_ts,start_ts) - @sleep_time_per_result_row * @row_count
|
||||
BETWEEN 0 AND @max_acceptable_delay
|
||||
AND attempt > 1;
|
||||
SELECT @aux2 AS "Expect 1";
|
||||
Expect 1
|
||||
1
|
||||
# Test 3: The query with SLEEP must be not cached.
|
||||
SELECT COUNT(*) = 4 INTO @aux3 FROM t_history
|
||||
WHERE end_cached = start_cached;
|
||||
SELECT @aux3 AS "Expect 1";
|
||||
Expect 1
|
||||
1
|
||||
DROP TABLE t1;
|
||||
DROP TEMPORARY TABLE t_history;
|
||||
SET @@global.query_cache_size = default;
|
||||
create table t1 select INET_ATON('255.255.0.1') as `a`;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
|
|
|
@ -29,15 +29,15 @@ show grants for mysqltest_1@localhost;
|
|||
Grants for mysqltest_1@localhost
|
||||
GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost'
|
||||
GRANT SELECT ON `mysqltest`.* TO 'mysqltest_1'@'localhost'
|
||||
grant USAGE on mysqltest.* to mysqltest_1@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "testsubject" ISSUER "MySQL AB";
|
||||
grant USAGE on mysqltest.* to mysqltest_1@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "testsubject" ISSUER "Monty Program Ab";
|
||||
show grants for mysqltest_1@localhost;
|
||||
Grants for mysqltest_1@localhost
|
||||
GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' REQUIRE ISSUER 'MySQL AB' SUBJECT 'testsubject' CIPHER 'EDH-RSA-DES-CBC3-SHA'
|
||||
GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' REQUIRE ISSUER 'Monty Program Ab' SUBJECT 'testsubject' CIPHER 'EDH-RSA-DES-CBC3-SHA'
|
||||
GRANT SELECT ON `mysqltest`.* TO 'mysqltest_1'@'localhost'
|
||||
revoke all privileges on mysqltest.* from mysqltest_1@localhost;
|
||||
show grants for mysqltest_1@localhost;
|
||||
Grants for mysqltest_1@localhost
|
||||
GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' REQUIRE ISSUER 'MySQL AB' SUBJECT 'testsubject' CIPHER 'EDH-RSA-DES-CBC3-SHA'
|
||||
GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' REQUIRE ISSUER 'Monty Program Ab' SUBJECT 'testsubject' CIPHER 'EDH-RSA-DES-CBC3-SHA'
|
||||
delete from mysql.user where user='mysqltest_1';
|
||||
flush privileges;
|
||||
delete from mysql.user where user='mysqltest_1';
|
||||
|
|
|
@ -443,3 +443,30 @@ DROP TABLE db1.t1, db1.t2;
|
|||
DROP USER mysqltest1@localhost;
|
||||
DROP DATABASE db1;
|
||||
End of 5.0 tests
|
||||
USE mysql;
|
||||
SELECT LEFT(CURRENT_USER(),INSTR(CURRENT_USER(),'@')-1) INTO @u;
|
||||
SELECT MID(CURRENT_USER(),INSTR(CURRENT_USER(),'@')+1) INTO @h;
|
||||
SELECT password FROM user WHERE user=@u AND host=@h INTO @pwd;
|
||||
SELECT user,host,password,insert_priv FROM user WHERE user=@u AND host=@h;
|
||||
user host password insert_priv
|
||||
root localhost Y
|
||||
UPDATE user SET insert_priv='N' WHERE user=@u AND host=@h;
|
||||
SELECT user,host,password,insert_priv FROM user WHERE user=@u AND host=@h;
|
||||
user host password insert_priv
|
||||
root localhost N
|
||||
GRANT INSERT ON *.* TO CURRENT_USER();
|
||||
SELECT user,host,password,insert_priv FROM user WHERE user=@u AND host=@h;
|
||||
user host password insert_priv
|
||||
root localhost Y
|
||||
UPDATE user SET insert_priv='N' WHERE user=@u AND host=@h;
|
||||
GRANT INSERT ON *.* TO CURRENT_USER() IDENTIFIED BY 'keksdose';
|
||||
SELECT user,host,password,insert_priv FROM user WHERE user=@u AND host=@h;
|
||||
user host password insert_priv
|
||||
root localhost *0BB7188CF0DE9B403BA66E9DD810D82652D002EB Y
|
||||
UPDATE user SET password=@pwd WHERE user=@u AND host=@h;
|
||||
SELECT user,host,password,insert_priv FROM user WHERE user=@u AND host=@h;
|
||||
user host password insert_priv
|
||||
root localhost Y
|
||||
FLUSH PRIVILEGES;
|
||||
USE test;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -2501,6 +2501,17 @@ SELECT a, MAX(b) FROM t WHERE b > 0 AND b < 2 GROUP BY a;
|
|||
a MAX(b)
|
||||
2 1
|
||||
DROP TABLE t;
|
||||
#
|
||||
# Bug #48472: Loose index scan inappropriately chosen for some WHERE
|
||||
# conditions
|
||||
#
|
||||
CREATE TABLE t (a INT, b INT, INDEX (a,b));
|
||||
INSERT INTO t VALUES (2,0), (2,0), (2,1), (2,1);
|
||||
INSERT INTO t SELECT * FROM t;
|
||||
SELECT a, MAX(b) FROM t WHERE 0=b+0 GROUP BY a;
|
||||
a MAX(b)
|
||||
2 0
|
||||
DROP TABLE t;
|
||||
End of 5.0 tests
|
||||
#
|
||||
# Bug #46607: Assertion failed: (cond_type == Item::FUNC_ITEM) results in
|
||||
|
|
|
@ -89,6 +89,7 @@ TRIGGERS
|
|||
USER_PRIVILEGES
|
||||
USER_STATISTICS
|
||||
VIEWS
|
||||
XTRADB_ADMIN_COMMAND
|
||||
XTRADB_ENHANCEMENTS
|
||||
columns_priv
|
||||
db
|
||||
|
@ -877,8 +878,8 @@ TABLE_PRIVILEGES TABLE_NAME select
|
|||
TABLE_STATISTICS TABLE_NAME select
|
||||
VIEWS TABLE_NAME select
|
||||
INNODB_BUFFER_POOL_PAGES_INDEX table_name select
|
||||
INNODB_INDEX_STATS table_name select
|
||||
INNODB_TABLE_STATS table_name select
|
||||
INNODB_INDEX_STATS table_name select
|
||||
delete from mysql.user where user='mysqltest_4';
|
||||
delete from mysql.db where user='mysqltest_4';
|
||||
flush privileges;
|
||||
|
|
|
@ -39,7 +39,7 @@ INNODB_CMP
|
|||
INNODB_RSEG
|
||||
XTRADB_ENHANCEMENTS
|
||||
INNODB_BUFFER_POOL_PAGES_INDEX
|
||||
INNODB_INDEX_STATS
|
||||
XTRADB_ADMIN_COMMAND
|
||||
INNODB_TRX
|
||||
INNODB_CMP_RESET
|
||||
INNODB_LOCK_WAITS
|
||||
|
@ -48,6 +48,7 @@ INNODB_LOCKS
|
|||
INNODB_CMPMEM
|
||||
INNODB_TABLE_STATS
|
||||
INNODB_BUFFER_POOL_PAGES_BLOB
|
||||
INNODB_INDEX_STATS
|
||||
SELECT t.table_name, c1.column_name
|
||||
FROM information_schema.tables t
|
||||
INNER JOIN
|
||||
|
@ -101,7 +102,7 @@ INNODB_CMP page_size
|
|||
INNODB_RSEG rseg_id
|
||||
XTRADB_ENHANCEMENTS name
|
||||
INNODB_BUFFER_POOL_PAGES_INDEX schema_name
|
||||
INNODB_INDEX_STATS table_name
|
||||
XTRADB_ADMIN_COMMAND result_message
|
||||
INNODB_TRX trx_id
|
||||
INNODB_CMP_RESET page_size
|
||||
INNODB_LOCK_WAITS requesting_trx_id
|
||||
|
@ -110,6 +111,7 @@ INNODB_LOCKS lock_id
|
|||
INNODB_CMPMEM page_size
|
||||
INNODB_TABLE_STATS table_name
|
||||
INNODB_BUFFER_POOL_PAGES_BLOB space_id
|
||||
INNODB_INDEX_STATS table_name
|
||||
SELECT t.table_name, c1.column_name
|
||||
FROM information_schema.tables t
|
||||
INNER JOIN
|
||||
|
@ -163,7 +165,7 @@ INNODB_CMP page_size
|
|||
INNODB_RSEG rseg_id
|
||||
XTRADB_ENHANCEMENTS name
|
||||
INNODB_BUFFER_POOL_PAGES_INDEX schema_name
|
||||
INNODB_INDEX_STATS table_name
|
||||
XTRADB_ADMIN_COMMAND result_message
|
||||
INNODB_TRX trx_id
|
||||
INNODB_CMP_RESET page_size
|
||||
INNODB_LOCK_WAITS requesting_trx_id
|
||||
|
@ -172,6 +174,7 @@ INNODB_LOCKS lock_id
|
|||
INNODB_CMPMEM page_size
|
||||
INNODB_TABLE_STATS table_name
|
||||
INNODB_BUFFER_POOL_PAGES_BLOB space_id
|
||||
INNODB_INDEX_STATS table_name
|
||||
select 1 as f1 from information_schema.tables where "CHARACTER_SETS"=
|
||||
(select cast(table_name as char) from information_schema.tables
|
||||
order by table_name limit 1) limit 1;
|
||||
|
@ -282,7 +285,7 @@ Database: information_schema
|
|||
| INNODB_RSEG |
|
||||
| XTRADB_ENHANCEMENTS |
|
||||
| INNODB_BUFFER_POOL_PAGES_INDEX |
|
||||
| INNODB_INDEX_STATS |
|
||||
| XTRADB_ADMIN_COMMAND |
|
||||
| INNODB_TRX |
|
||||
| INNODB_CMP_RESET |
|
||||
| INNODB_LOCK_WAITS |
|
||||
|
@ -291,6 +294,7 @@ Database: information_schema
|
|||
| INNODB_CMPMEM |
|
||||
| INNODB_TABLE_STATS |
|
||||
| INNODB_BUFFER_POOL_PAGES_BLOB |
|
||||
| INNODB_INDEX_STATS |
|
||||
+---------------------------------------+
|
||||
Database: INFORMATION_SCHEMA
|
||||
+---------------------------------------+
|
||||
|
@ -334,7 +338,7 @@ Database: INFORMATION_SCHEMA
|
|||
| INNODB_RSEG |
|
||||
| XTRADB_ENHANCEMENTS |
|
||||
| INNODB_BUFFER_POOL_PAGES_INDEX |
|
||||
| INNODB_INDEX_STATS |
|
||||
| XTRADB_ADMIN_COMMAND |
|
||||
| INNODB_TRX |
|
||||
| INNODB_CMP_RESET |
|
||||
| INNODB_LOCK_WAITS |
|
||||
|
@ -343,6 +347,7 @@ Database: INFORMATION_SCHEMA
|
|||
| INNODB_CMPMEM |
|
||||
| INNODB_TABLE_STATS |
|
||||
| INNODB_BUFFER_POOL_PAGES_BLOB |
|
||||
| INNODB_INDEX_STATS |
|
||||
+---------------------------------------+
|
||||
Wildcard: inf_rmation_schema
|
||||
+--------------------+
|
||||
|
@ -352,5 +357,5 @@ Wildcard: inf_rmation_schema
|
|||
+--------------------+
|
||||
SELECT table_schema, count(*) FROM information_schema.TABLES WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test', 'mysqltest') AND table_name<>'ndb_binlog_index' AND table_name<>'ndb_apply_status' GROUP BY TABLE_SCHEMA;
|
||||
table_schema count(*)
|
||||
information_schema 47
|
||||
information_schema 48
|
||||
mysql 22
|
||||
|
|
|
@ -197,7 +197,7 @@ c1 c2
|
|||
5 9
|
||||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=100, @@SESSION.AUTO_INCREMENT_OFFSET=10;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 100
|
||||
auto_increment_offset 10
|
||||
|
@ -230,7 +230,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -269,7 +269,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -282,7 +282,7 @@ SELECT * FROM t1;
|
|||
c1
|
||||
-1
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=100, @@SESSION.AUTO_INCREMENT_OFFSET=10;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 100
|
||||
auto_increment_offset 10
|
||||
|
@ -315,7 +315,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -330,7 +330,7 @@ SELECT * FROM t1;
|
|||
c1
|
||||
1
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=100, @@SESSION.AUTO_INCREMENT_OFFSET=10;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 100
|
||||
auto_increment_offset 10
|
||||
|
@ -370,7 +370,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -385,7 +385,7 @@ SELECT * FROM t1;
|
|||
c1
|
||||
1
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=100, @@SESSION.AUTO_INCREMENT_OFFSET=10;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 100
|
||||
auto_increment_offset 10
|
||||
|
@ -419,7 +419,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -434,7 +434,7 @@ c1
|
|||
1
|
||||
9223372036854775794
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=2, @@SESSION.AUTO_INCREMENT_OFFSET=10;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 2
|
||||
auto_increment_offset 10
|
||||
|
@ -452,7 +452,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -467,7 +467,7 @@ c1
|
|||
1
|
||||
18446744073709551603
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=2, @@SESSION.AUTO_INCREMENT_OFFSET=10;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 2
|
||||
auto_increment_offset 10
|
||||
|
@ -485,7 +485,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -500,7 +500,7 @@ c1
|
|||
1
|
||||
18446744073709551603
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=5, @@SESSION.AUTO_INCREMENT_OFFSET=7;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 5
|
||||
auto_increment_offset 7
|
||||
|
@ -514,7 +514,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -533,7 +533,7 @@ c1
|
|||
-9223372036854775806
|
||||
1
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=3, @@SESSION.AUTO_INCREMENT_OFFSET=3;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 3
|
||||
auto_increment_offset 3
|
||||
|
@ -550,7 +550,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -568,7 +568,7 @@ SET @@SESSION.AUTO_INCREMENT_INCREMENT=1152921504606846976, @@SESSION.AUTO_INCRE
|
|||
Warnings:
|
||||
Warning 1292 Truncated incorrect auto_increment_increment value: '1152921504606846976'
|
||||
Warning 1292 Truncated incorrect auto_increment_offset value: '1152921504606846976'
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 65535
|
||||
auto_increment_offset 65535
|
||||
|
@ -581,7 +581,7 @@ c1
|
|||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SET @@INSERT_ID=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -875,11 +875,11 @@ ALTER TABLE t1 CHANGE c1 d1 INT NOT NULL AUTO_INCREMENT;
|
|||
SELECT * FROM t1;
|
||||
d1
|
||||
1
|
||||
3
|
||||
2
|
||||
SELECT * FROM t1;
|
||||
d1
|
||||
1
|
||||
3
|
||||
2
|
||||
INSERT INTO t1 VALUES(null);
|
||||
Got one of the listed errors
|
||||
ALTER TABLE t1 AUTO_INCREMENT = 3;
|
||||
|
@ -888,16 +888,16 @@ Table Create Table
|
|||
t1 CREATE TABLE `t1` (
|
||||
`d1` int(11) NOT NULL AUTO_INCREMENT,
|
||||
PRIMARY KEY (`d1`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(null);
|
||||
SELECT * FROM t1;
|
||||
d1
|
||||
1
|
||||
2
|
||||
3
|
||||
4
|
||||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
SHOW VARIABLES LIKE "auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
|
@ -1126,3 +1126,61 @@ SELECT * FROM T1;
|
|||
c1 c2
|
||||
10 0
|
||||
DROP TABLE T1;
|
||||
CREATE TABLE T1(C1 DOUBLE AUTO_INCREMENT KEY, C2 CHAR(10)) ENGINE=InnoDB;
|
||||
INSERT INTO T1(C1, C2) VALUES (1, 'innodb'), (3, 'innodb');
|
||||
INSERT INTO T1(C2) VALUES ('innodb');
|
||||
SHOW CREATE TABLE T1;
|
||||
Table Create Table
|
||||
T1 CREATE TABLE `T1` (
|
||||
`C1` double NOT NULL AUTO_INCREMENT,
|
||||
`C2` char(10) DEFAULT NULL,
|
||||
PRIMARY KEY (`C1`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=latin1
|
||||
DROP TABLE T1;
|
||||
CREATE TABLE T1(C1 FLOAT AUTO_INCREMENT KEY, C2 CHAR(10)) ENGINE=InnoDB;
|
||||
INSERT INTO T1(C1, C2) VALUES (1, 'innodb'), (3, 'innodb');
|
||||
INSERT INTO T1(C2) VALUES ('innodb');
|
||||
SHOW CREATE TABLE T1;
|
||||
Table Create Table
|
||||
T1 CREATE TABLE `T1` (
|
||||
`C1` float NOT NULL AUTO_INCREMENT,
|
||||
`C2` char(10) DEFAULT NULL,
|
||||
PRIMARY KEY (`C1`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=latin1
|
||||
DROP TABLE T1;
|
||||
CREATE TABLE t1 (c1 INT AUTO_INCREMENT PRIMARY KEY) ENGINE=InnoDB;
|
||||
INSERT INTO t1 SET c1 = 1;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) NOT NULL AUTO_INCREMENT,
|
||||
PRIMARY KEY (`c1`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 SET c1 = 2;
|
||||
INSERT INTO t1 SET c1 = -1;
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
-1
|
||||
1
|
||||
2
|
||||
INSERT INTO t1 SET c1 = -1;
|
||||
Got one of the listed errors
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) NOT NULL AUTO_INCREMENT,
|
||||
PRIMARY KEY (`c1`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1
|
||||
REPLACE INTO t1 VALUES (-1);
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
-1
|
||||
1
|
||||
2
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) NOT NULL AUTO_INCREMENT,
|
||||
PRIMARY KEY (`c1`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
|
35
mysql-test/r/innodb-consistent.result
Normal file
35
mysql-test/r/innodb-consistent.result
Normal file
|
@ -0,0 +1,35 @@
|
|||
drop table if exists t1;
|
||||
set session transaction isolation level read committed;
|
||||
create table t1(a int not null) engine=innodb DEFAULT CHARSET=latin1;
|
||||
create table t2 like t1;
|
||||
insert into t2 values (1),(2),(3),(4),(5),(6),(7);
|
||||
set autocommit=0;
|
||||
begin;
|
||||
replace into t1 select * from t2;
|
||||
set session transaction isolation level read committed;
|
||||
set autocommit=0;
|
||||
delete from t2 where a=5;
|
||||
commit;
|
||||
delete from t2;
|
||||
commit;
|
||||
commit;
|
||||
begin;
|
||||
insert into t1 select * from t2;
|
||||
set session transaction isolation level read committed;
|
||||
set autocommit=0;
|
||||
delete from t2 where a=5;
|
||||
commit;
|
||||
delete from t2;
|
||||
commit;
|
||||
commit;
|
||||
select * from t1;
|
||||
a
|
||||
1
|
||||
2
|
||||
3
|
||||
4
|
||||
5
|
||||
6
|
||||
7
|
||||
drop table t1;
|
||||
drop table t2;
|
|
@ -1,4 +1,3 @@
|
|||
SET @save_innodb_file_format_check=@@global.innodb_file_format_check;
|
||||
create table t1(a int not null, b int, c char(10) not null, d varchar(20)) engine = innodb;
|
||||
insert into t1 values (5,5,'oo','oo'),(4,4,'tr','tr'),(3,4,'ad','ad'),(2,3,'ak','ak');
|
||||
commit;
|
||||
|
@ -629,7 +628,7 @@ drop table t1;
|
|||
create table t1(a int not null, b int, c char(10), d varchar(20), primary key (a)) engine = innodb;
|
||||
insert into t1 values (1,1,'ab','ab'),(2,2,'ac','ac'),(3,3,'ac','ac'),(4,4,'afe','afe'),(5,4,'affe','affe');
|
||||
alter table t1 add unique index (b), add unique index (c), add unique index (d);
|
||||
ERROR 23000: Duplicate entry '4' for key 'b'
|
||||
ERROR 23000: Duplicate entry 'ac' for key 'c'
|
||||
alter table t1 add unique index (c), add unique index (b), add index (d);
|
||||
ERROR 23000: Duplicate entry 'ac' for key 'c'
|
||||
show create table t1;
|
||||
|
@ -970,6 +969,7 @@ create index t1u on t1 (u(1));
|
|||
drop table t1;
|
||||
set global innodb_file_per_table=0;
|
||||
set global innodb_file_format=Antelope;
|
||||
set global innodb_file_format_check=Antelope;
|
||||
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
|
||||
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
|
||||
CREATE TABLE t1(
|
||||
|
@ -1171,4 +1171,3 @@ a b
|
|||
3 a
|
||||
3 b
|
||||
DROP TABLE t1;
|
||||
SET GLOBAL innodb_file_format_check=@save_innodb_file_format_check;
|
||||
|
|
|
@ -23,6 +23,7 @@ select @@innodb_lock_wait_timeout;
|
|||
create table t1(a int primary key)engine=innodb;
|
||||
begin;
|
||||
insert into t1 values(1),(2),(3);
|
||||
set innodb_lock_wait_timeout=5;
|
||||
select * from t1 for update;
|
||||
commit;
|
||||
a
|
||||
|
@ -31,8 +32,15 @@ a
|
|||
3
|
||||
begin;
|
||||
insert into t1 values(4);
|
||||
set innodb_lock_wait_timeout=2;
|
||||
set @a= current_timestamp();
|
||||
select * from t1 for update;
|
||||
commit;
|
||||
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
||||
set @b= current_timestamp();
|
||||
set @c= timestampdiff(SECOND, @a, @b);
|
||||
select if(@c >= 1 and @c <= 10, 'OK', concat("NOT OK, time passed=", @c));
|
||||
if(@c >= 1 and @c <= 10, 'OK', concat("NOT OK, time passed=", @c))
|
||||
OK
|
||||
commit;
|
||||
drop table t1;
|
||||
set global innodb_lock_wait_timeout=50;
|
||||
|
|
|
@ -196,15 +196,15 @@ drop table t1;
|
|||
set innodb_strict_mode = on;
|
||||
create table t1 (id int primary key) engine = innodb key_block_size = 0;
|
||||
ERROR HY000: Can't create table 'test.t1' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: invalid KEY_BLOCK_SIZE = 0. Valid values are [1, 2, 4, 8, 16]
|
||||
Warning 1478 InnoDB: invalid KEY_BLOCK_SIZE = 0. Valid values are [1, 2, 4, 8, 16]
|
||||
Error 1005 Can't create table 'test.t1' (errno: 1478)
|
||||
create table t2 (id int primary key) engine = innodb key_block_size = 9;
|
||||
ERROR HY000: Can't create table 'test.t2' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Warning 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Error 1005 Can't create table 'test.t2' (errno: 1478)
|
||||
create table t3 (id int primary key) engine = innodb key_block_size = 1;
|
||||
create table t4 (id int primary key) engine = innodb key_block_size = 2;
|
||||
|
@ -233,30 +233,30 @@ key_block_size = 8 row_format = compressed;
|
|||
create table t2 (id int primary key) engine = innodb
|
||||
key_block_size = 8 row_format = redundant;
|
||||
ERROR HY000: Can't create table 'test.t2' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: cannot specify ROW_FORMAT = REDUNDANT with KEY_BLOCK_SIZE.
|
||||
Warning 1478 InnoDB: cannot specify ROW_FORMAT = REDUNDANT with KEY_BLOCK_SIZE.
|
||||
Error 1005 Can't create table 'test.t2' (errno: 1478)
|
||||
create table t3 (id int primary key) engine = innodb
|
||||
key_block_size = 8 row_format = compact;
|
||||
ERROR HY000: Can't create table 'test.t3' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: cannot specify ROW_FORMAT = COMPACT with KEY_BLOCK_SIZE.
|
||||
Warning 1478 InnoDB: cannot specify ROW_FORMAT = COMPACT with KEY_BLOCK_SIZE.
|
||||
Error 1005 Can't create table 'test.t3' (errno: 1478)
|
||||
create table t4 (id int primary key) engine = innodb
|
||||
key_block_size = 8 row_format = dynamic;
|
||||
ERROR HY000: Can't create table 'test.t4' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: cannot specify ROW_FORMAT = DYNAMIC with KEY_BLOCK_SIZE.
|
||||
Warning 1478 InnoDB: cannot specify ROW_FORMAT = DYNAMIC with KEY_BLOCK_SIZE.
|
||||
Error 1005 Can't create table 'test.t4' (errno: 1478)
|
||||
create table t5 (id int primary key) engine = innodb
|
||||
key_block_size = 8 row_format = default;
|
||||
ERROR HY000: Can't create table 'test.t5' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: cannot specify ROW_FORMAT = COMPACT with KEY_BLOCK_SIZE.
|
||||
Warning 1478 InnoDB: cannot specify ROW_FORMAT = COMPACT with KEY_BLOCK_SIZE.
|
||||
Error 1005 Can't create table 'test.t5' (errno: 1478)
|
||||
SELECT table_schema, table_name, row_format
|
||||
FROM information_schema.tables WHERE engine='innodb';
|
||||
|
@ -266,26 +266,26 @@ drop table t1;
|
|||
create table t1 (id int primary key) engine = innodb
|
||||
key_block_size = 9 row_format = redundant;
|
||||
ERROR HY000: Can't create table 'test.t1' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Error 1478 InnoDB: cannot specify ROW_FORMAT = REDUNDANT with KEY_BLOCK_SIZE.
|
||||
Warning 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Warning 1478 InnoDB: cannot specify ROW_FORMAT = REDUNDANT with KEY_BLOCK_SIZE.
|
||||
Error 1005 Can't create table 'test.t1' (errno: 1478)
|
||||
create table t2 (id int primary key) engine = innodb
|
||||
key_block_size = 9 row_format = compact;
|
||||
ERROR HY000: Can't create table 'test.t2' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Error 1478 InnoDB: cannot specify ROW_FORMAT = COMPACT with KEY_BLOCK_SIZE.
|
||||
Warning 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Warning 1478 InnoDB: cannot specify ROW_FORMAT = COMPACT with KEY_BLOCK_SIZE.
|
||||
Error 1005 Can't create table 'test.t2' (errno: 1478)
|
||||
create table t2 (id int primary key) engine = innodb
|
||||
key_block_size = 9 row_format = dynamic;
|
||||
ERROR HY000: Can't create table 'test.t2' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Error 1478 InnoDB: cannot specify ROW_FORMAT = DYNAMIC with KEY_BLOCK_SIZE.
|
||||
Warning 1478 InnoDB: invalid KEY_BLOCK_SIZE = 9. Valid values are [1, 2, 4, 8, 16]
|
||||
Warning 1478 InnoDB: cannot specify ROW_FORMAT = DYNAMIC with KEY_BLOCK_SIZE.
|
||||
Error 1005 Can't create table 'test.t2' (errno: 1478)
|
||||
SELECT table_schema, table_name, row_format
|
||||
FROM information_schema.tables WHERE engine='innodb';
|
||||
|
@ -293,45 +293,45 @@ table_schema table_name row_format
|
|||
set global innodb_file_per_table = off;
|
||||
create table t1 (id int primary key) engine = innodb key_block_size = 1;
|
||||
ERROR HY000: Can't create table 'test.t1' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Error 1005 Can't create table 'test.t1' (errno: 1478)
|
||||
create table t2 (id int primary key) engine = innodb key_block_size = 2;
|
||||
ERROR HY000: Can't create table 'test.t2' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Error 1005 Can't create table 'test.t2' (errno: 1478)
|
||||
create table t3 (id int primary key) engine = innodb key_block_size = 4;
|
||||
ERROR HY000: Can't create table 'test.t3' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Error 1005 Can't create table 'test.t3' (errno: 1478)
|
||||
create table t4 (id int primary key) engine = innodb key_block_size = 8;
|
||||
ERROR HY000: Can't create table 'test.t4' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Error 1005 Can't create table 'test.t4' (errno: 1478)
|
||||
create table t5 (id int primary key) engine = innodb key_block_size = 16;
|
||||
ERROR HY000: Can't create table 'test.t5' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_per_table.
|
||||
Error 1005 Can't create table 'test.t5' (errno: 1478)
|
||||
create table t6 (id int primary key) engine = innodb row_format = compressed;
|
||||
ERROR HY000: Can't create table 'test.t6' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: ROW_FORMAT=COMPRESSED requires innodb_file_per_table.
|
||||
Warning 1478 InnoDB: ROW_FORMAT=COMPRESSED requires innodb_file_per_table.
|
||||
Error 1005 Can't create table 'test.t6' (errno: 1478)
|
||||
create table t7 (id int primary key) engine = innodb row_format = dynamic;
|
||||
ERROR HY000: Can't create table 'test.t7' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: ROW_FORMAT=DYNAMIC requires innodb_file_per_table.
|
||||
Warning 1478 InnoDB: ROW_FORMAT=DYNAMIC requires innodb_file_per_table.
|
||||
Error 1005 Can't create table 'test.t7' (errno: 1478)
|
||||
create table t8 (id int primary key) engine = innodb row_format = compact;
|
||||
create table t9 (id int primary key) engine = innodb row_format = redundant;
|
||||
|
@ -345,45 +345,45 @@ set global innodb_file_per_table = on;
|
|||
set global innodb_file_format = `0`;
|
||||
create table t1 (id int primary key) engine = innodb key_block_size = 1;
|
||||
ERROR HY000: Can't create table 'test.t1' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Error 1005 Can't create table 'test.t1' (errno: 1478)
|
||||
create table t2 (id int primary key) engine = innodb key_block_size = 2;
|
||||
ERROR HY000: Can't create table 'test.t2' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Error 1005 Can't create table 'test.t2' (errno: 1478)
|
||||
create table t3 (id int primary key) engine = innodb key_block_size = 4;
|
||||
ERROR HY000: Can't create table 'test.t3' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Error 1005 Can't create table 'test.t3' (errno: 1478)
|
||||
create table t4 (id int primary key) engine = innodb key_block_size = 8;
|
||||
ERROR HY000: Can't create table 'test.t4' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Error 1005 Can't create table 'test.t4' (errno: 1478)
|
||||
create table t5 (id int primary key) engine = innodb key_block_size = 16;
|
||||
ERROR HY000: Can't create table 'test.t5' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Warning 1478 InnoDB: KEY_BLOCK_SIZE requires innodb_file_format > Antelope.
|
||||
Error 1005 Can't create table 'test.t5' (errno: 1478)
|
||||
create table t6 (id int primary key) engine = innodb row_format = compressed;
|
||||
ERROR HY000: Can't create table 'test.t6' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: ROW_FORMAT=COMPRESSED requires innodb_file_format > Antelope.
|
||||
Warning 1478 InnoDB: ROW_FORMAT=COMPRESSED requires innodb_file_format > Antelope.
|
||||
Error 1005 Can't create table 'test.t6' (errno: 1478)
|
||||
create table t7 (id int primary key) engine = innodb row_format = dynamic;
|
||||
ERROR HY000: Can't create table 'test.t7' (errno: 1478)
|
||||
show errors;
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Error 1478 InnoDB: ROW_FORMAT=DYNAMIC requires innodb_file_format > Antelope.
|
||||
Warning 1478 InnoDB: ROW_FORMAT=DYNAMIC requires innodb_file_format > Antelope.
|
||||
Error 1005 Can't create table 'test.t7' (errno: 1478)
|
||||
create table t8 (id int primary key) engine = innodb row_format = compact;
|
||||
create table t9 (id int primary key) engine = innodb row_format = redundant;
|
||||
|
|
|
@ -3090,7 +3090,7 @@ ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
|||
commit;
|
||||
drop table t1, t2, t3, t5, t6, t8, t9;
|
||||
CREATE TABLE t1 (DB_ROW_ID int) engine=innodb;
|
||||
ERROR HY000: Can't create table 'test.t1' (errno: -1)
|
||||
ERROR 42000: Incorrect column name 'DB_ROW_ID'
|
||||
CREATE TABLE t1 (
|
||||
a BIGINT(20) NOT NULL,
|
||||
PRIMARY KEY (a)
|
||||
|
|
|
@ -1,4 +1,2 @@
|
|||
set @old_innodb_file_format=@@innodb_file_format;
|
||||
set @old_innodb_file_per_table=@@innodb_file_per_table;
|
||||
SET GLOBAL innodb_file_format='Barracuda';
|
||||
SET GLOBAL innodb_file_per_table=ON;
|
||||
|
|
|
@ -1,14 +1,6 @@
|
|||
create table bug44369 (DB_ROW_ID int) engine=innodb;
|
||||
ERROR HY000: Can't create table 'test.bug44369' (errno: -1)
|
||||
ERROR 42000: Incorrect column name 'DB_ROW_ID'
|
||||
create table bug44369 (db_row_id int) engine=innodb;
|
||||
ERROR HY000: Can't create table 'test.bug44369' (errno: -1)
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Warning 1005 Error creating table 'test/bug44369' with column name 'db_row_id'. 'db_row_id' is a reserved name. Please try to re-create the table with a different column name.
|
||||
Error 1005 Can't create table 'test.bug44369' (errno: -1)
|
||||
ERROR 42000: Incorrect column name 'db_row_id'
|
||||
create table bug44369 (db_TRX_Id int) engine=innodb;
|
||||
ERROR HY000: Can't create table 'test.bug44369' (errno: -1)
|
||||
show warnings;
|
||||
Level Code Message
|
||||
Warning 1005 Error creating table 'test/bug44369' with column name 'db_TRX_Id'. 'db_TRX_Id' is a reserved name. Please try to re-create the table with a different column name.
|
||||
Error 1005 Can't create table 'test.bug44369' (errno: -1)
|
||||
ERROR 42000: Incorrect column name 'db_TRX_Id'
|
||||
|
|
7
mysql-test/r/innodb_bug44571.result
Normal file
7
mysql-test/r/innodb_bug44571.result
Normal file
|
@ -0,0 +1,7 @@
|
|||
CREATE TABLE bug44571 (foo INT) ENGINE=InnoDB;
|
||||
ALTER TABLE bug44571 CHANGE foo bar INT;
|
||||
ALTER TABLE bug44571 ADD INDEX bug44571b (foo);
|
||||
ERROR 42000: Key column 'foo' doesn't exist in table
|
||||
ALTER TABLE bug44571 ADD INDEX bug44571b (bar);
|
||||
CREATE INDEX bug44571c ON bug44571 (bar);
|
||||
DROP TABLE bug44571;
|
9
mysql-test/r/innodb_bug46676.result
Normal file
9
mysql-test/r/innodb_bug46676.result
Normal file
|
@ -0,0 +1,9 @@
|
|||
SET foreign_key_checks=0;
|
||||
CREATE TABLE t1 (id int, foreign key (id) references t2(id)) ENGINE=INNODB;
|
||||
CREATE TABLE t2 (id int, foreign key (id) references t1(id)) ENGINE=INNODB;
|
||||
SET foreign_key_checks=1;
|
||||
SELECT COUNT(*) FROM information_schema.key_column_usage WHERE REFERENCED_TABLE_NAME in ('t1', 't2');
|
||||
COUNT(*)
|
||||
2
|
||||
SET foreign_key_checks=0;
|
||||
DROP TABLE t1, t2;
|
24
mysql-test/r/innodb_bug47167.result
Normal file
24
mysql-test/r/innodb_bug47167.result
Normal file
|
@ -0,0 +1,24 @@
|
|||
set @old_innodb_file_format_check=@@innodb_file_format_check;
|
||||
select @old_innodb_file_format_check;
|
||||
@old_innodb_file_format_check
|
||||
Antelope
|
||||
set global innodb_file_format_check = Barracuda;
|
||||
select @@innodb_file_format_check;
|
||||
@@innodb_file_format_check
|
||||
Barracuda
|
||||
set global innodb_file_format_check = DEFAULT;
|
||||
select @@innodb_file_format_check;
|
||||
@@innodb_file_format_check
|
||||
Barracuda
|
||||
set global innodb_file_format_check = @old_innodb_file_format_check;
|
||||
select @@innodb_file_format_check;
|
||||
@@innodb_file_format_check
|
||||
Antelope
|
||||
set global innodb_file_format_check = cheetah;
|
||||
ERROR HY000: Incorrect arguments to SET
|
||||
set global innodb_file_format_check = Bear;
|
||||
ERROR HY000: Incorrect arguments to SET
|
||||
set global innodb_file_format_check = on;
|
||||
ERROR HY000: Incorrect arguments to SET
|
||||
set global innodb_file_format_check = off;
|
||||
ERROR HY000: Incorrect arguments to SET
|
|
@ -1,4 +1,3 @@
|
|||
set @old_innodb_file_format=@@innodb_file_format;
|
||||
call mtr.add_suppression("InnoDB: invalid innodb_file_format_check value");
|
||||
select @@innodb_file_format;
|
||||
@@innodb_file_format
|
||||
|
@ -32,8 +31,6 @@ select @@innodb_file_format_check;
|
|||
@@innodb_file_format_check
|
||||
Barracuda
|
||||
set global innodb_file_format_check=default;
|
||||
Warnings:
|
||||
Warning 1210 Ignoring SET innodb_file_format=on
|
||||
select @@innodb_file_format_check;
|
||||
@@innodb_file_format_check
|
||||
Barracuda
|
||||
|
@ -44,5 +41,4 @@ ERROR HY000: Incorrect arguments to SET
|
|||
select @@innodb_file_format_check;
|
||||
@@innodb_file_format_check
|
||||
Barracuda
|
||||
set global innodb_file_format=@old_innodb_file_format;
|
||||
set global innodb_file_format_check=Antelope;
|
||||
set global innodb_file_format_check=antelope;
|
||||
|
|
|
@ -48,6 +48,24 @@ commit;
|
|||
set autocommit=default;
|
||||
drop table t1;
|
||||
#
|
||||
# Bug #37183 insert ignore into .. select ... hangs
|
||||
# after deadlock was encountered
|
||||
#
|
||||
create table t1(id int primary key,v int)engine=innodb;
|
||||
insert into t1 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(7,7);
|
||||
create table t2 like t1;
|
||||
begin;
|
||||
update t1 set v=id*2 where id=1;
|
||||
begin;
|
||||
update t1 set v=id*2 where id=2;
|
||||
update t1 set v=id*2 where id=2;
|
||||
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
||||
insert ignore into t2 select * from t1 where id=1;
|
||||
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
||||
rollback;
|
||||
rollback;
|
||||
drop table t1, t2;
|
||||
#
|
||||
# Bug#41756 Strange error messages about locks from InnoDB
|
||||
#
|
||||
drop table if exists t1;
|
||||
|
|
|
@ -2251,4 +2251,26 @@ c >= '2009-10-09 00:00:00.001' AND c <= '2009-10-09 00:00:00.00';
|
|||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL Impossible WHERE noticed after reading const tables
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug #46175: NULL read_view and consistent read assertion
|
||||
#
|
||||
CREATE TABLE t1(a CHAR(13),KEY(a)) ENGINE=innodb;
|
||||
CREATE TABLE t2(b DATETIME,KEY(b)) ENGINE=innodb;
|
||||
INSERT INTO t1 VALUES (),();
|
||||
INSERT INTO t2 VALUES (),();
|
||||
CREATE OR REPLACE VIEW v1 AS SELECT 1 FROM t2
|
||||
WHERE b =(SELECT a FROM t1 LIMIT 1);
|
||||
CREATE PROCEDURE p1(num INT)
|
||||
BEGIN
|
||||
DECLARE i INT DEFAULT 0;
|
||||
REPEAT
|
||||
SHOW CREATE VIEW v1;
|
||||
SET i:=i+1;
|
||||
UNTIL i>num END REPEAT;
|
||||
END|
|
||||
# Should not crash
|
||||
# Should not crash
|
||||
DROP PROCEDURE p1;
|
||||
DROP VIEW v1;
|
||||
DROP TABLE t1,t2;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
SET @old_innodb_file_format=@@innodb_file_format;
|
||||
SET @old_innodb_file_per_table=@@innodb_file_per_table;
|
||||
SET @old_innodb_file_format_check=@@innodb_file_format_check;
|
||||
SET GLOBAL innodb_file_format='Barracuda';
|
||||
SET GLOBAL innodb_file_per_table=ON;
|
||||
DROP TABLE IF EXISTS `test1`;
|
||||
|
@ -29,4 +28,4 @@ ALTER TABLE test1 ENGINE=MyISAM;
|
|||
DROP TABLE test1;
|
||||
SET GLOBAL innodb_file_format=@old_innodb_file_format;
|
||||
SET GLOBAL innodb_file_per_table=@old_innodb_file_per_table;
|
||||
SET GLOBAL innodb_file_format_check=@old_innodb_file_format_check;
|
||||
set global innodb_file_format_check=Antelope;
|
||||
|
|
|
@ -229,5 +229,4 @@ a: b
|
|||
</row>
|
||||
</resultset>
|
||||
drop table t1;
|
||||
|
||||
End of tests
|
||||
End of 5.0 tests
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
SET GLOBAL max_connections = 1000;
|
||||
select 0 as "before_use_test" ;
|
||||
before_use_test
|
||||
0
|
||||
|
|
|
@ -753,4 +753,16 @@ b
|
|||
100
|
||||
NULL
|
||||
DROP TABLE t1, t2;
|
||||
#
|
||||
# Bug #48475: DISTINCT is ignored with GROUP BY WITH ROLLUP
|
||||
# and only const tables
|
||||
CREATE TABLE t1 (a INT);
|
||||
CREATE TABLE t2 (b INT);
|
||||
INSERT INTO t1 VALUES (1);
|
||||
INSERT INTO t2 VALUES (1);
|
||||
SELECT DISTINCT b FROM t1, t2 GROUP BY a, b WITH ROLLUP;
|
||||
b
|
||||
1
|
||||
NULL
|
||||
DROP TABLE t1, t2;
|
||||
End of 5.0 tests
|
||||
|
|
|
@ -3,8 +3,10 @@ create table t1(f1 int);
|
|||
insert into t1 values (5);
|
||||
grant select on test.* to ssl_user1@localhost require SSL;
|
||||
grant select on test.* to ssl_user2@localhost require cipher "DHE-RSA-AES256-SHA";
|
||||
grant select on test.* to ssl_user3@localhost require cipher "DHE-RSA-AES256-SHA" AND SUBJECT "/C=SE/ST=Uppsala/O=MySQL AB/emailAddress=abstract.mysql.developer@mysql.com";
|
||||
grant select on test.* to ssl_user4@localhost require cipher "DHE-RSA-AES256-SHA" AND SUBJECT "/C=SE/ST=Uppsala/O=MySQL AB/emailAddress=abstract.mysql.developer@mysql.com" ISSUER "/C=SE/ST=Uppsala/L=Uppsala/O=MySQL AB";
|
||||
grant select on test.* to ssl_user3@localhost require cipher
|
||||
"DHE-RSA-AES256-SHA" AND SUBJECT "/C=FI/ST=Tuusula/O=Monty Program Ab/emailAddress=abstract.developer@askmonty.org";
|
||||
grant select on test.* to ssl_user4@localhost require cipher
|
||||
"DHE-RSA-AES256-SHA" AND SUBJECT "/C=FI/ST=Tuusula/O=Monty Program Ab/emailAddress=abstract.developer@askmonty.org" ISSUER "/C=FI/ST=Tuusula/O=Monty Program Ab/emailAddress=abstract.developer@askmonty.org";
|
||||
grant select on test.* to ssl_user5@localhost require cipher "DHE-RSA-AES256-SHA" AND SUBJECT "xxx";
|
||||
flush privileges;
|
||||
connect(localhost,ssl_user5,,test,MASTER_PORT,MASTER_SOCKET);
|
||||
|
@ -44,9 +46,9 @@ ERROR 42000: DELETE command denied to user 'ssl_user4'@'localhost' for table 't1
|
|||
drop user ssl_user1@localhost, ssl_user2@localhost,
|
||||
ssl_user3@localhost, ssl_user4@localhost, ssl_user5@localhost;
|
||||
drop table t1;
|
||||
mysqltest: Could not open connection 'default': 2026 SSL connection error
|
||||
mysqltest: Could not open connection 'default': 2026 SSL connection error
|
||||
mysqltest: Could not open connection 'default': 2026 SSL connection error
|
||||
mysqltest: Could not open connection 'default': 2026 SSL error: ASN: bad other signature confirmation
|
||||
mysqltest: Could not open connection 'default': 2026 SSL error: ASN: bad other signature confirmation
|
||||
mysqltest: Could not open connection 'default': 2026 SSL error: ASN: bad other signature confirmation
|
||||
SSL error: Unable to get private key from ''
|
||||
mysqltest: Could not open connection 'default': 2026 SSL connection error
|
||||
SSL error: Unable to get certificate from ''
|
||||
|
|
|
@ -1444,6 +1444,27 @@ FROM t3;
|
|||
2
|
||||
NULL
|
||||
DROP TABLE t1, t2, t3;
|
||||
#
|
||||
# Bug #42760: Select doesn't return desired results when we have null
|
||||
# values
|
||||
#
|
||||
CREATE TABLE t1 (
|
||||
a INT,
|
||||
c INT,
|
||||
UNIQUE KEY a_c (a,c),
|
||||
KEY (a));
|
||||
INSERT INTO t1 VALUES (1, 10), (2, NULL);
|
||||
# Must use ref-or-null on the a_c index
|
||||
EXPLAIN
|
||||
SELECT 1 AS col FROM t1 WHERE a=2 AND (c=10 OR c IS NULL) ORDER BY c;
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 ref_or_null a_c,a a_c 10 const,const 1 Using where
|
||||
# Must return 1 row
|
||||
SELECT 1 AS col FROM t1 WHERE a=2 AND (c=10 OR c IS NULL) ORDER BY c;
|
||||
col
|
||||
1
|
||||
DROP TABLE t1;
|
||||
End of 5.0 tests
|
||||
CREATE TABLE t2 (a varchar(32), b int(11), c float, d double,
|
||||
UNIQUE KEY a (a,b,c), KEY b (b), KEY c (c));
|
||||
CREATE TABLE t1 (a varchar(32), b char(3), UNIQUE KEY a (a,b), KEY b (b));
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
drop table if exists t1, t2;
|
||||
CREATE TABLE t1 (a INT, b INT)
|
||||
PARTITION BY LIST (a)
|
||||
SUBPARTITION BY HASH (b)
|
||||
(PARTITION p1 VALUES IN (1));
|
||||
ALTER TABLE t1 ADD COLUMN c INT;
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (
|
||||
a int NOT NULL,
|
||||
b int NOT NULL);
|
||||
|
@ -50,6 +56,13 @@ t1 CREATE TABLE `t1` (
|
|||
PARTITION p3 VALUES LESS THAN (733969) ENGINE = MyISAM,
|
||||
PARTITION pmax VALUES LESS THAN MAXVALUE ENGINE = MyISAM) */
|
||||
DROP TABLE t1;
|
||||
create table t1 (a int NOT NULL, b varchar(5) NOT NULL)
|
||||
default charset=utf8
|
||||
partition by list (a)
|
||||
subpartition by key (b)
|
||||
(partition p0 values in (1),
|
||||
partition p1 values in (2));
|
||||
drop table t1;
|
||||
create table t1 (a int, b int, key(a))
|
||||
partition by list (a)
|
||||
( partition p0 values in (1),
|
||||
|
@ -2045,10 +2058,15 @@ DROP TABLE t1;
|
|||
#
|
||||
# Bug #45807: crash accessing partitioned table and sql_mode
|
||||
# contains ONLY_FULL_GROUP_BY
|
||||
# Bug#46923: select count(*) from partitioned table fails with
|
||||
# ONLY_FULL_GROUP_BY
|
||||
#
|
||||
SET SESSION SQL_MODE='ONLY_FULL_GROUP_BY';
|
||||
CREATE TABLE t1(id INT,KEY(id)) ENGINE=MYISAM
|
||||
PARTITION BY HASH(id) PARTITIONS 2;
|
||||
SELECT COUNT(*) FROM t1;
|
||||
COUNT(*)
|
||||
0
|
||||
DROP TABLE t1;
|
||||
SET SESSION SQL_MODE=DEFAULT;
|
||||
#
|
||||
|
|
|
@ -1302,6 +1302,15 @@ drop procedure f3;
|
|||
drop procedure f4;
|
||||
drop table t1;
|
||||
set GLOBAL query_cache_size=0;
|
||||
set GLOBAL query_cache_size=100000;
|
||||
set SESSION query_cache_size=10000;
|
||||
ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL
|
||||
set global query_cache_limit=100;
|
||||
set global query_cache_size=100;
|
||||
set global query_cache_type=demand;
|
||||
set GLOBAL query_cache_type=default;
|
||||
set GLOBAL query_cache_limit=default;
|
||||
set GLOBAL query_cache_size=default;
|
||||
End of 4.1 tests
|
||||
SET GLOBAL query_cache_size=102400;
|
||||
create table t1(a int);
|
||||
|
@ -1707,6 +1716,95 @@ Variable_name Value
|
|||
Qcache_hits 2
|
||||
DROP TABLE t1;
|
||||
SET GLOBAL query_cache_size= default;
|
||||
#------------------------------------------------------------------------
|
||||
# Tests for Bug#6760 and Bug#12689
|
||||
SET @row_count = 4;
|
||||
SET @sleep_time_per_result_row = 1;
|
||||
SET @max_acceptable_delay = 2;
|
||||
SET @@global.query_cache_size = 1024 * 64;
|
||||
DROP TEMPORARY TABLE IF EXISTS t_history;
|
||||
DROP TABLE IF EXISTS t1;
|
||||
CREATE TEMPORARY TABLE t_history (attempt SMALLINT,
|
||||
start_ts DATETIME, end_ts DATETIME,
|
||||
start_cached INTEGER, end_cached INTEGER);
|
||||
CREATE TABLE t1 (f1 BIGINT);
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 4 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 4 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 4 + 1;
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 3 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 3 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 3 + 1;
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 2 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 2 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 2 + 1;
|
||||
INSERT INTO t_history
|
||||
SET attempt = 4 - 1 + 1, start_ts = NOW(),
|
||||
start_cached = 0;
|
||||
SELECT *, SLEEP(@sleep_time_per_result_row) FROM t1;
|
||||
f1 SLEEP(@sleep_time_per_result_row)
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
1 0
|
||||
UPDATE t_history SET end_ts = NOW()
|
||||
WHERE attempt = 4 - 1 + 1;
|
||||
UPDATE t_history SET end_cached = 0
|
||||
WHERE attempt = 4 - 1 + 1;
|
||||
# Test 1: Does the query with SLEEP need a reasonable time?
|
||||
SELECT COUNT(*) >= 4 - 1 INTO @aux1 FROM t_history
|
||||
WHERE TIMEDIFF(end_ts,start_ts) - @sleep_time_per_result_row * @row_count
|
||||
BETWEEN 0 AND @max_acceptable_delay;
|
||||
SELECT @aux1 AS "Expect 1";
|
||||
Expect 1
|
||||
1
|
||||
# Test 2: Does the query with SLEEP need a reasonable time even in case
|
||||
# of the non first execution?
|
||||
SELECT COUNT(*) >= 4 - 1 - 1 INTO @aux2 FROM t_history
|
||||
WHERE TIMEDIFF(end_ts,start_ts) - @sleep_time_per_result_row * @row_count
|
||||
BETWEEN 0 AND @max_acceptable_delay
|
||||
AND attempt > 1;
|
||||
SELECT @aux2 AS "Expect 1";
|
||||
Expect 1
|
||||
1
|
||||
# Test 3: The query with SLEEP must be not cached.
|
||||
SELECT COUNT(*) = 4 INTO @aux3 FROM t_history
|
||||
WHERE end_cached = start_cached;
|
||||
SELECT @aux3 AS "Expect 1";
|
||||
Expect 1
|
||||
1
|
||||
DROP TABLE t1;
|
||||
DROP TEMPORARY TABLE t_history;
|
||||
SET @@global.query_cache_size = default;
|
||||
End of 5.0 tests
|
||||
SET GLOBAL query_cache_size=1024*1024*512;
|
||||
CREATE TABLE t1 (a ENUM('rainbow'));
|
||||
|
|
|
@ -382,3 +382,55 @@ set GLOBAL query_cache_type=default;
|
|||
set GLOBAL query_cache_limit=default;
|
||||
set GLOBAL query_cache_min_res_unit=default;
|
||||
set GLOBAL query_cache_size=default;
|
||||
drop table if exists t1|
|
||||
create table t1 (
|
||||
id char(16) not null default '',
|
||||
data int not null
|
||||
)|
|
||||
drop procedure if exists bug3583|
|
||||
drop procedure if exists bug3583|
|
||||
create procedure bug3583()
|
||||
begin
|
||||
declare c int;
|
||||
select * from t1;
|
||||
select count(*) into c from t1;
|
||||
select c;
|
||||
end|
|
||||
insert into t1 values ("x", 3), ("y", 5)|
|
||||
set @x = @@query_cache_size|
|
||||
set global query_cache_size = 10*1024*1024|
|
||||
flush status|
|
||||
flush query cache|
|
||||
show status like 'Qcache_hits'|
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
call bug3583()|
|
||||
id data
|
||||
x 3
|
||||
y 5
|
||||
c
|
||||
2
|
||||
show status like 'Qcache_hits'|
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
call bug3583()|
|
||||
id data
|
||||
x 3
|
||||
y 5
|
||||
c
|
||||
2
|
||||
call bug3583()|
|
||||
id data
|
||||
x 3
|
||||
y 5
|
||||
c
|
||||
2
|
||||
show status like 'Qcache_hits'|
|
||||
Variable_name Value
|
||||
Qcache_hits 2
|
||||
set global query_cache_size = @x|
|
||||
flush status|
|
||||
flush query cache|
|
||||
delete from t1|
|
||||
drop procedure bug3583|
|
||||
drop table t1|
|
||||
|
|
|
@ -1603,4 +1603,54 @@ SELECT str_to_date('', '%Y-%m-%d');
|
|||
str_to_date('', '%Y-%m-%d')
|
||||
0000-00-00
|
||||
DROP TABLE t1, t2;
|
||||
#
|
||||
# Bug#48459: valgrind errors with query using 'Range checked for each
|
||||
# record'
|
||||
#
|
||||
CREATE TABLE t1 (
|
||||
a INT,
|
||||
b CHAR(2),
|
||||
c INT,
|
||||
d INT,
|
||||
KEY ( c ),
|
||||
KEY ( d, a, b ( 2 ) ),
|
||||
KEY ( b ( 1 ) )
|
||||
);
|
||||
INSERT INTO t1 VALUES ( NULL, 'a', 1, 2 ), ( NULL, 'a', 1, 2 ),
|
||||
( 1, 'a', 1, 2 ), ( 1, 'a', 1, 2 );
|
||||
CREATE TABLE t2 (
|
||||
a INT,
|
||||
c INT,
|
||||
e INT,
|
||||
KEY ( e )
|
||||
);
|
||||
INSERT INTO t2 VALUES ( 1, 1, NULL ), ( 1, 1, NULL );
|
||||
# Should not give Valgrind warnings
|
||||
SELECT 1
|
||||
FROM t1, t2
|
||||
WHERE t1.d <> '1' AND t1.b > '1'
|
||||
AND t1.a = t2.a AND t1.c = t2.c;
|
||||
1
|
||||
1
|
||||
1
|
||||
1
|
||||
1
|
||||
DROP TABLE t1, t2;
|
||||
#
|
||||
# Bug #48665: sql-bench's insert test fails due to wrong result
|
||||
#
|
||||
CREATE TABLE t1 (a INT, b INT, PRIMARY KEY (a));
|
||||
INSERT INTO t1 VALUES (0,0), (1,1);
|
||||
EXPLAIN
|
||||
SELECT * FROM t1 FORCE INDEX (PRIMARY)
|
||||
WHERE (a>=1 AND a<=2) OR (a>=4 AND a<=5) OR (a>=0 AND a <=10);
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
@ @ @ range @ @ @ @ @ @
|
||||
# Should return 2 rows
|
||||
SELECT * FROM t1 FORCE INDEX (PRIMARY)
|
||||
WHERE (a>=1 AND a<=2) OR (a>=4 AND a<=5) OR (a>=0 AND a <=10);
|
||||
a b
|
||||
0 0
|
||||
1 1
|
||||
DROP TABLE t1;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -4426,6 +4426,20 @@ ROW(a,a) <=> ROW((SELECT 1 FROM t1 WHERE 1=2),(SELECT 1 FROM t1))
|
|||
INTO @var0;
|
||||
ERROR 21000: Subquery returns more than 1 row
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug #48458: simple query tries to allocate enormous amount of
|
||||
# memory
|
||||
#
|
||||
CREATE TABLE t1(a INT NOT NULL, b YEAR);
|
||||
INSERT INTO t1 VALUES ();
|
||||
Warnings:
|
||||
Warning 1364 Field 'a' doesn't have a default value
|
||||
CREATE TABLE t2(c INT);
|
||||
# Should not err out because of out-of-memory
|
||||
SELECT 1 FROM t2 JOIN t1 ON 1=1
|
||||
WHERE a != '1' AND NOT a >= b OR NOT ROW(b,a )<> ROW(a,a);
|
||||
1
|
||||
DROP TABLE t1,t2;
|
||||
End of 5.0 tests
|
||||
create table t1(a INT, KEY (a));
|
||||
INSERT INTO t1 VALUES (1),(2),(3),(4),(5);
|
||||
|
@ -4576,4 +4590,47 @@ field2
|
|||
15:13:38
|
||||
drop table A,AA,B,BB;
|
||||
#end of test for bug#45266
|
||||
#
|
||||
# BUG#48052: Valgrind warning - uninitialized value in init_read_record()
|
||||
#
|
||||
CREATE TABLE t1 (
|
||||
pk int(11) NOT NULL,
|
||||
i int(11) DEFAULT NULL,
|
||||
v varchar(1) DEFAULT NULL,
|
||||
PRIMARY KEY (pk)
|
||||
);
|
||||
INSERT INTO t1 VALUES (2,7,'m');
|
||||
INSERT INTO t1 VALUES (3,9,'m');
|
||||
SELECT v
|
||||
FROM t1
|
||||
WHERE NOT pk > 0
|
||||
HAVING v <= 't'
|
||||
ORDER BY pk;
|
||||
v
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug#49489 Uninitialized cache led to a wrong result.
|
||||
#
|
||||
CREATE TABLE t1(c1 DOUBLE(5,4));
|
||||
INSERT INTO t1 VALUES (9.1234);
|
||||
SELECT * FROM t1 WHERE c1 < 9.12345;
|
||||
c1
|
||||
9.1234
|
||||
DROP TABLE t1;
|
||||
# End of test for bug#49489.
|
||||
#
|
||||
# Bug #49517: Inconsistent behavior while using
|
||||
# NULLable BIGINT and INT columns in comparison
|
||||
#
|
||||
CREATE TABLE t1(a BIGINT UNSIGNED NOT NULL, b BIGINT NULL, c INT NULL);
|
||||
INSERT INTO t1 VALUES(105, NULL, NULL);
|
||||
SELECT * FROM t1 WHERE b < 102;
|
||||
a b c
|
||||
SELECT * FROM t1 WHERE c < 102;
|
||||
a b c
|
||||
SELECT * FROM t1 WHERE 102 < b;
|
||||
a b c
|
||||
SELECT * FROM t1 WHERE 102 < c;
|
||||
a b c
|
||||
DROP TABLE t1;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -252,13 +252,11 @@ drop table t1;
|
|||
flush tables;
|
||||
show open tables;
|
||||
Database Table In_use Name_locked
|
||||
mysql general_log 0 0
|
||||
create table t1(n int);
|
||||
insert into t1 values (1);
|
||||
show open tables;
|
||||
Database Table In_use Name_locked
|
||||
test t1 0 0
|
||||
mysql general_log 0 0
|
||||
drop table t1;
|
||||
create table t1 (a int not null, b VARCHAR(10), INDEX (b) ) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" ENGINE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed;
|
||||
show create table t1;
|
||||
|
@ -1454,4 +1452,10 @@ GRANT PROCESS ON *.* TO test_u@localhost;
|
|||
SHOW ENGINE MYISAM MUTEX;
|
||||
SHOW ENGINE MYISAM STATUS;
|
||||
DROP USER test_u@localhost;
|
||||
#
|
||||
# Bug #48985: show create table crashes if previous access to the table
|
||||
# was killed
|
||||
#
|
||||
SHOW CREATE TABLE non_existent;
|
||||
ERROR 70100: Query execution was interrupted
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
call mtr.add_suppression("Column count of mysql.proc is wrong. Expected 20, found 19. The table is probably corrupted");
|
||||
use test;
|
||||
drop procedure if exists bug14233;
|
||||
drop function if exists bug14233;
|
||||
|
@ -11,11 +12,13 @@ create table t1 (id int);
|
|||
create trigger t1_ai after insert on t1 for each row call bug14233();
|
||||
alter table mysql.proc drop type;
|
||||
call bug14233();
|
||||
ERROR HY000: Failed to load routine test.bug14233. The table mysql.proc is missing, corrupt, or contains bad data (internal code -5)
|
||||
ERROR HY000: Column count of mysql.proc is wrong. Expected 20, found 19. The table is probably corrupted
|
||||
create view v1 as select bug14233_f();
|
||||
ERROR HY000: Failed to load routine test.bug14233_f. The table mysql.proc is missing, corrupt, or contains bad data (internal code -5)
|
||||
ERROR HY000: Column count of mysql.proc is wrong. Expected 20, found 19. The table is probably corrupted
|
||||
insert into t1 values (0);
|
||||
ERROR HY000: Failed to load routine test.bug14233. The table mysql.proc is missing, corrupt, or contains bad data (internal code -5)
|
||||
ERROR HY000: Column count of mysql.proc is wrong. Expected 20, found 19. The table is probably corrupted
|
||||
show procedure status;
|
||||
ERROR HY000: Column count of mysql.proc is wrong. Expected 20, found 19. The table is probably corrupted
|
||||
flush table mysql.proc;
|
||||
call bug14233();
|
||||
ERROR HY000: Incorrect information in file: './mysql/proc.frm'
|
||||
|
@ -88,3 +91,28 @@ show procedure status where db=DATABASE();
|
|||
Db Name Type Definer Modified Created Security_type Comment character_set_client collation_connection Database Collation
|
||||
show function status where db=DATABASE();
|
||||
Db Name Type Definer Modified Created Security_type Comment character_set_client collation_connection Database Collation
|
||||
DROP TABLE IF EXISTS proc_backup;
|
||||
DROP PROCEDURE IF EXISTS p1;
|
||||
# Backup the proc table
|
||||
RENAME TABLE mysql.proc TO proc_backup;
|
||||
CREATE TABLE mysql.proc LIKE proc_backup;
|
||||
FLUSH TABLE mysql.proc;
|
||||
# Test with a valid table.
|
||||
CREATE PROCEDURE p1()
|
||||
SET @foo = 10;
|
||||
CALL p1();
|
||||
SHOW PROCEDURE STATUS;
|
||||
Db Name Type Definer Modified Created Security_type Comment character_set_client collation_connection Database Collation
|
||||
test p1 PROCEDURE root@localhost 0000-00-00 00:00:00 0000-00-00 00:00:00 DEFINER latin1 latin1_swedish_ci latin1_swedish_ci
|
||||
# Modify a field of the table.
|
||||
ALTER TABLE mysql.proc MODIFY comment CHAR (32);
|
||||
CREATE PROCEDURE p2()
|
||||
SET @foo = 10;
|
||||
ERROR HY000: Cannot load from mysql.proc. The table is probably corrupted
|
||||
# Procedure loaded from the cache
|
||||
CALL p1();
|
||||
SHOW PROCEDURE STATUS;
|
||||
ERROR HY000: Cannot load from mysql.proc. The table is probably corrupted
|
||||
DROP TABLE mysql.proc;
|
||||
RENAME TABLE proc_backup TO mysql.proc;
|
||||
FLUSH TABLE mysql.proc;
|
||||
|
|
|
@ -510,4 +510,60 @@ DROP USER mysqltest_u1@localhost;
|
|||
DROP PROCEDURE p_suid;
|
||||
DROP FUNCTION f_suid;
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug #48872 : Privileges for stored functions ignored if function name
|
||||
# is mixed case
|
||||
#
|
||||
CREATE DATABASE B48872;
|
||||
USE B48872;
|
||||
CREATE TABLE `TestTab` (id INT);
|
||||
INSERT INTO `TestTab` VALUES (1),(2);
|
||||
CREATE FUNCTION `f_Test`() RETURNS INT RETURN 123;
|
||||
CREATE FUNCTION `f_Test_denied`() RETURNS INT RETURN 123;
|
||||
CREATE USER 'tester';
|
||||
CREATE USER 'Tester';
|
||||
GRANT SELECT ON TABLE `TestTab` TO 'tester';
|
||||
GRANT EXECUTE ON FUNCTION `f_Test` TO 'tester';
|
||||
GRANT EXECUTE ON FUNCTION `f_Test_denied` TO 'Tester';
|
||||
SELECT f_Test();
|
||||
f_Test()
|
||||
123
|
||||
SELECT * FROM TestTab;
|
||||
id
|
||||
1
|
||||
2
|
||||
SELECT * FROM TestTab;
|
||||
id
|
||||
1
|
||||
2
|
||||
SELECT `f_Test`();
|
||||
`f_Test`()
|
||||
123
|
||||
SELECT `F_TEST`();
|
||||
`F_TEST`()
|
||||
123
|
||||
SELECT f_Test();
|
||||
f_Test()
|
||||
123
|
||||
SELECT F_TEST();
|
||||
F_TEST()
|
||||
123
|
||||
SELECT * FROM TestTab;
|
||||
SELECT `f_Test`();
|
||||
SELECT `F_TEST`();
|
||||
SELECT f_Test();
|
||||
SELECT F_TEST();
|
||||
SELECT `f_Test_denied`();
|
||||
`f_Test_denied`()
|
||||
123
|
||||
SELECT `F_TEST_DENIED`();
|
||||
`F_TEST_DENIED`()
|
||||
123
|
||||
DROP TABLE `TestTab`;
|
||||
DROP FUNCTION `f_Test`;
|
||||
DROP FUNCTION `f_Test_denied`;
|
||||
USE test;
|
||||
DROP USER 'tester';
|
||||
DROP USER 'Tester';
|
||||
DROP DATABASE B48872;
|
||||
End of 5.0 tests.
|
||||
|
|
|
@ -6979,6 +6979,64 @@ CALL p1;
|
|||
ERROR 42S22: Unknown column 'A.b' in 'IN/ALL/ANY subquery'
|
||||
DROP PROCEDURE p1;
|
||||
DROP TABLE t1, t2;
|
||||
#
|
||||
# Bug#47627: SET @@{global.session}.local_variable in stored routine causes crash
|
||||
# Bug#48626: Crash or lost connection using SET for declared variables with @@
|
||||
#
|
||||
DROP PROCEDURE IF EXISTS p1;
|
||||
DROP PROCEDURE IF EXISTS p2;
|
||||
DROP PROCEDURE IF EXISTS p3;
|
||||
CREATE PROCEDURE p1()
|
||||
BEGIN
|
||||
DECLARE v INT DEFAULT 0;
|
||||
SET @@SESSION.v= 10;
|
||||
END//
|
||||
ERROR HY000: Unknown system variable 'v'
|
||||
CREATE PROCEDURE p2()
|
||||
BEGIN
|
||||
DECLARE v INT DEFAULT 0;
|
||||
SET v= 10;
|
||||
END//
|
||||
call p2()//
|
||||
CREATE PROCEDURE p3()
|
||||
BEGIN
|
||||
DECLARE v INT DEFAULT 0;
|
||||
SELECT @@SESSION.v;
|
||||
END//
|
||||
ERROR HY000: Unknown system variable 'v'
|
||||
CREATE PROCEDURE p4()
|
||||
BEGIN
|
||||
DECLARE v INT DEFAULT 0;
|
||||
SET @@GLOBAL.v= 10;
|
||||
END//
|
||||
ERROR HY000: Unknown system variable 'v'
|
||||
CREATE PROCEDURE p5()
|
||||
BEGIN
|
||||
DECLARE init_connect INT DEFAULT 0;
|
||||
SET init_connect= 10;
|
||||
SET @@GLOBAL.init_connect= 'SELECT 1';
|
||||
SET @@SESSION.IDENTITY= 1;
|
||||
SELECT @@SESSION.IDENTITY;
|
||||
SELECT @@GLOBAL.init_connect;
|
||||
SELECT init_connect;
|
||||
END//
|
||||
CREATE PROCEDURE p6()
|
||||
BEGIN
|
||||
DECLARE v INT DEFAULT 0;
|
||||
SET @@v= 0;
|
||||
END//
|
||||
ERROR HY000: Unknown system variable 'v'
|
||||
SET @old_init_connect= @@GLOBAL.init_connect;
|
||||
CALL p5();
|
||||
@@SESSION.IDENTITY
|
||||
1
|
||||
@@GLOBAL.init_connect
|
||||
SELECT 1
|
||||
init_connect
|
||||
10
|
||||
SET @@GLOBAL.init_connect= @old_init_connect;
|
||||
DROP PROCEDURE p2;
|
||||
DROP PROCEDURE p5;
|
||||
# ------------------------------------------------------------------
|
||||
# -- End of 5.1 tests
|
||||
# ------------------------------------------------------------------
|
||||
|
|
|
@ -25,58 +25,6 @@ call bug4902_2()|
|
|||
show warnings|
|
||||
Level Code Message
|
||||
drop procedure bug4902_2|
|
||||
drop table if exists t1|
|
||||
create table t1 (
|
||||
id char(16) not null default '',
|
||||
data int not null
|
||||
)|
|
||||
drop procedure if exists bug3583|
|
||||
drop procedure if exists bug3583|
|
||||
create procedure bug3583()
|
||||
begin
|
||||
declare c int;
|
||||
select * from t1;
|
||||
select count(*) into c from t1;
|
||||
select c;
|
||||
end|
|
||||
insert into t1 values ("x", 3), ("y", 5)|
|
||||
set @x = @@query_cache_size|
|
||||
set global query_cache_size = 10*1024*1024|
|
||||
flush status|
|
||||
flush query cache|
|
||||
show status like 'Qcache_hits'|
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
call bug3583()|
|
||||
id data
|
||||
x 3
|
||||
y 5
|
||||
c
|
||||
2
|
||||
show status like 'Qcache_hits'|
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
call bug3583()|
|
||||
id data
|
||||
x 3
|
||||
y 5
|
||||
c
|
||||
2
|
||||
call bug3583()|
|
||||
id data
|
||||
x 3
|
||||
y 5
|
||||
c
|
||||
2
|
||||
show status like 'Qcache_hits'|
|
||||
Variable_name Value
|
||||
Qcache_hits 2
|
||||
set global query_cache_size = @x|
|
||||
flush status|
|
||||
flush query cache|
|
||||
delete from t1|
|
||||
drop procedure bug3583|
|
||||
drop table t1|
|
||||
drop procedure if exists bug6807|
|
||||
create procedure bug6807()
|
||||
begin
|
||||
|
|
|
@ -1448,33 +1448,6 @@ isave
|
|||
1
|
||||
2
|
||||
drop table t1, t2, t3;
|
||||
CREATE TABLE t1 (id INTEGER);
|
||||
CREATE TABLE t2 (id INTEGER);
|
||||
INSERT INTO t2 VALUES (1),(2);
|
||||
CREATE TRIGGER t1_test AFTER INSERT ON t1 FOR EACH ROW
|
||||
INSERT INTO t2 VALUES (new.id);
|
||||
SELECT GET_LOCK('B26162',120);
|
||||
GET_LOCK('B26162',120)
|
||||
1
|
||||
SELECT 'rl_acquirer', GET_LOCK('B26162',120), id FROM t2 WHERE id = 1;
|
||||
SET SESSION LOW_PRIORITY_UPDATES=1;
|
||||
SET GLOBAL LOW_PRIORITY_UPDATES=1;
|
||||
INSERT INTO t1 VALUES (5);
|
||||
SELECT 'rl_contender', id FROM t2 WHERE id > 1;
|
||||
SELECT RELEASE_LOCK('B26162');
|
||||
RELEASE_LOCK('B26162')
|
||||
1
|
||||
rl_acquirer GET_LOCK('B26162',120) id
|
||||
rl_acquirer 1 1
|
||||
SELECT RELEASE_LOCK('B26162');
|
||||
RELEASE_LOCK('B26162')
|
||||
1
|
||||
rl_contender id
|
||||
rl_contender 2
|
||||
DROP TRIGGER t1_test;
|
||||
DROP TABLE t1,t2;
|
||||
SET SESSION LOW_PRIORITY_UPDATES=DEFAULT;
|
||||
SET GLOBAL LOW_PRIORITY_UPDATES=DEFAULT;
|
||||
|
||||
Bug#28502 Triggers that update another innodb table will block
|
||||
on X lock unnecessarily
|
||||
|
|
|
@ -445,6 +445,33 @@ DROP TABLE t2;
|
|||
DROP TABLE t1;
|
||||
DROP DATABASE mysqltest_db1;
|
||||
USE test;
|
||||
CREATE TABLE t1 (id INTEGER);
|
||||
CREATE TABLE t2 (id INTEGER);
|
||||
INSERT INTO t2 VALUES (1),(2);
|
||||
CREATE TRIGGER t1_test AFTER INSERT ON t1 FOR EACH ROW
|
||||
INSERT INTO t2 VALUES (new.id);
|
||||
SELECT GET_LOCK('B26162',120);
|
||||
GET_LOCK('B26162',120)
|
||||
1
|
||||
SELECT 'rl_acquirer', GET_LOCK('B26162',120), id FROM t2 WHERE id = 1;
|
||||
SET SESSION LOW_PRIORITY_UPDATES=1;
|
||||
SET GLOBAL LOW_PRIORITY_UPDATES=1;
|
||||
INSERT INTO t1 VALUES (5);
|
||||
SELECT 'rl_contender', id FROM t2 WHERE id > 1;
|
||||
SELECT RELEASE_LOCK('B26162');
|
||||
RELEASE_LOCK('B26162')
|
||||
1
|
||||
rl_acquirer GET_LOCK('B26162',120) id
|
||||
rl_acquirer 1 1
|
||||
SELECT RELEASE_LOCK('B26162');
|
||||
RELEASE_LOCK('B26162')
|
||||
1
|
||||
rl_contender id
|
||||
rl_contender 2
|
||||
DROP TRIGGER t1_test;
|
||||
DROP TABLE t1,t2;
|
||||
SET SESSION LOW_PRIORITY_UPDATES=DEFAULT;
|
||||
SET GLOBAL LOW_PRIORITY_UPDATES=DEFAULT;
|
||||
End of 5.0 tests.
|
||||
drop table if exists t1;
|
||||
create table t1 (i int);
|
||||
|
|
|
@ -1630,3 +1630,287 @@ SELECT my_col FROM t1;
|
|||
my_col
|
||||
0.012345687012345687012345687012
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug#45261: Crash, stored procedure + decimal
|
||||
#
|
||||
DROP TABLE IF EXISTS t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 81 */ 100000000000000000000000000000000000000000000000000000000000000000000000000000001
|
||||
AS c1;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,0) NO 0
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
99999999999999999999999999999999999999999999999999999999999999999
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 81 */ 100000000000000000000000000000000000000000000000000000000000000000000000000000001.
|
||||
AS c1;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,0) NO 0
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
99999999999999999999999999999999999999999999999999999999999999999
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 81 */ 100000000000000000000000000000000000000000000000000000000000000000000000000000001.1 /* 1 */
|
||||
AS c1;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,0) NO 0
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
99999999999999999999999999999999999999999999999999999999999999999
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 82 */ 1000000000000000000000000000000000000000000000000000000000000000000000000000000001
|
||||
AS c1;
|
||||
Warnings:
|
||||
Error 1292 Truncated incorrect DECIMAL value: ''
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,0) NO 0
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
99999999999999999999999999999999999999999999999999999999999999999
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 40 */ 1000000000000000000000000000000000000001.1000000000000000000000000000000000000001 /* 40 */
|
||||
AS c1;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
99999999999999999999999999999999999.999999999999999999999999999999
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 1 */ 1.10000000000000000000000000000000000000000000000000000000000000000000000000000001 /* 80 */
|
||||
AS c1;
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(31,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
1.100000000000000000000000000000
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 1 */ 1.100000000000000000000000000000000000000000000000000000000000000000000000000000001 /* 81 */
|
||||
AS c1;
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(31,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
1.100000000000000000000000000000
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
.100000000000000000000000000000000000000000000000000000000000000000000000000000001 /* 81 */
|
||||
AS c1;
|
||||
Warnings:
|
||||
Note 1265 Data truncated for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(30,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
0.100000000000000000000000000000
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 45 */ 123456789012345678901234567890123456789012345.123456789012345678901234567890123456789012345 /* 45 */
|
||||
AS c1;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
99999999999999999999999999999999999.999999999999999999999999999999
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 65 */ 12345678901234567890123456789012345678901234567890123456789012345.1 /* 1 */
|
||||
AS c1;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,1) NO 0.0
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
9999999999999999999999999999999999999999999999999999999999999999.9
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
/* 66 */ 123456789012345678901234567890123456789012345678901234567890123456.1 /* 1 */
|
||||
AS c1;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,1) NO 0.0
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
9999999999999999999999999999999999999999999999999999999999999999.9
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT
|
||||
.123456789012345678901234567890123456789012345678901234567890123456 /* 66 */
|
||||
AS c1;
|
||||
Warnings:
|
||||
Note 1265 Data truncated for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(30,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
0.123456789012345678901234567890
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 AS SELECT 123.1234567890123456789012345678901 /* 31 */ AS c1;
|
||||
Warnings:
|
||||
Note 1265 Data truncated for column 'c1' at row 1
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(33,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
123.123456789012345678901234567890
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 SELECT 1.1 + CAST(1 AS DECIMAL(65,30)) AS c1;
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,30) NO 0.000000000000000000000000000000
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
2.100000000000000000000000000000
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Test that the integer and decimal parts are properly calculated.
|
||||
#
|
||||
CREATE TABLE t1 (a DECIMAL(30,30));
|
||||
INSERT INTO t1 VALUES (0.1),(0.2),(0.3);
|
||||
CREATE TABLE t2 SELECT MIN(a + 0.0000000000000000000000000000001) AS c1 FROM t1;
|
||||
Warnings:
|
||||
Note 1265 Data truncated for column 'c1' at row 3
|
||||
DESC t2;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(32,30) YES NULL
|
||||
DROP TABLE t1,t2;
|
||||
CREATE TABLE t1 (a DECIMAL(30,30));
|
||||
INSERT INTO t1 VALUES (0.1),(0.2),(0.3);
|
||||
CREATE TABLE t2 SELECT IFNULL(a + 0.0000000000000000000000000000001, NULL) AS c1 FROM t1;
|
||||
Warnings:
|
||||
Note 1265 Data truncated for column 'c1' at row 1
|
||||
Note 1265 Data truncated for column 'c1' at row 2
|
||||
Note 1265 Data truncated for column 'c1' at row 3
|
||||
DESC t2;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(34,0) YES NULL
|
||||
DROP TABLE t1,t2;
|
||||
CREATE TABLE t1 (a DECIMAL(30,30));
|
||||
INSERT INTO t1 VALUES (0.1),(0.2),(0.3);
|
||||
CREATE TABLE t2 SELECT CASE a WHEN 0.1 THEN 0.0000000000000000000000000000000000000000000000000000000000000000001 END AS c1 FROM t1;
|
||||
Warnings:
|
||||
Note 1265 Data truncated for column 'c1' at row 1
|
||||
DESC t2;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,30) YES NULL
|
||||
DROP TABLE t1,t2;
|
||||
#
|
||||
# Test that variables get maximum precision.
|
||||
#
|
||||
SET @decimal= 1.1;
|
||||
CREATE TABLE t1 SELECT @decimal AS c1;
|
||||
DESC t1;
|
||||
Field Type Null Key Default Extra
|
||||
c1 decimal(65,30) YES NULL
|
||||
SELECT * FROM t1;
|
||||
c1
|
||||
1.100000000000000000000000000000
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug #45261 : Crash, stored procedure + decimal
|
||||
# Original test by the reporter.
|
||||
#
|
||||
# should not crash
|
||||
CREATE TABLE t1
|
||||
SELECT .123456789012345678901234567890123456789012345678901234567890123456 AS a;
|
||||
Warnings:
|
||||
Note 1265 Data truncated for column 'a' at row 1
|
||||
DROP TABLE t1;
|
||||
CREATE PROCEDURE test_proc()
|
||||
BEGIN
|
||||
# The las non critical CUSER definition is:
|
||||
# DECLARE mycursor CURSOR FOR SELECT 1 %
|
||||
# .12345678912345678912345678912345678912345678912345678912345678912 AS my_col;
|
||||
DECLARE mycursor CURSOR FOR
|
||||
SELECT 1 %
|
||||
.123456789123456789123456789123456789123456789123456789123456789123456789123456789
|
||||
AS my_col;
|
||||
OPEN mycursor;
|
||||
CLOSE mycursor;
|
||||
END|
|
||||
# should not crash
|
||||
CALL test_proc();
|
||||
DROP PROCEDURE test_proc;
|
||||
#
|
||||
# Bug #48370 Absolutely wrong calculations with GROUP BY and
|
||||
# decimal fields when using IF
|
||||
#
|
||||
CREATE TABLE currencies (id int, rate decimal(16,4),
|
||||
PRIMARY KEY (id), KEY (rate));
|
||||
INSERT INTO currencies VALUES (11,0.7028);
|
||||
INSERT INTO currencies VALUES (1,1);
|
||||
CREATE TABLE payments (
|
||||
id int,
|
||||
supplier_id int,
|
||||
status int,
|
||||
currency_id int,
|
||||
vat decimal(7,4),
|
||||
PRIMARY KEY (id),
|
||||
KEY currency_id (currency_id),
|
||||
KEY supplier_id (supplier_id)
|
||||
);
|
||||
INSERT INTO payments (id,status,vat,supplier_id,currency_id) VALUES
|
||||
(3001,2,0.0000,344,11), (1,2,0.0000,1,1);
|
||||
CREATE TABLE sub_tasks (
|
||||
id int,
|
||||
currency_id int,
|
||||
price decimal(16,4),
|
||||
discount decimal(10,4),
|
||||
payment_id int,
|
||||
PRIMARY KEY (id),
|
||||
KEY currency_id (currency_id),
|
||||
KEY payment_id (payment_id)
|
||||
) ;
|
||||
INSERT INTO sub_tasks (id, price, discount, payment_id, currency_id) VALUES
|
||||
(52, 12.60, 0, 3001, 11), (56, 14.58, 0, 3001, 11);
|
||||
# should return 1 and the same values in col 2 and 3
|
||||
select STRAIGHT_JOIN
|
||||
(1 + PAY.vat) AS mult,
|
||||
SUM(ROUND((SUB.price - ROUND(ROUND(SUB.price, 2) * SUB.discount, 2)) *
|
||||
CUR.rate / CUR.rate, 2)
|
||||
) v_net_with_discount,
|
||||
SUM(ROUND((SUB.price - ROUND(ROUND(SUB.price, 2) * SUB.discount, 1)) *
|
||||
CUR.rate / CUR.rate , 2)
|
||||
* (1 + PAY.vat)
|
||||
) v_total
|
||||
from
|
||||
currencies CUR, payments PAY, sub_tasks SUB
|
||||
where
|
||||
SUB.payment_id = PAY.id and
|
||||
PAY.currency_id = CUR.id and
|
||||
PAY.id > 2
|
||||
group by PAY.id + 1;
|
||||
mult v_net_with_discount v_total
|
||||
1.0000 27.18 27.180000
|
||||
DROP TABLE currencies, payments, sub_tasks;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -46,3 +46,267 @@ a
|
|||
2001
|
||||
drop table t1;
|
||||
End of 5.0 tests
|
||||
#
|
||||
# Bug #49480: WHERE using YEAR columns returns unexpected results
|
||||
#
|
||||
CREATE TABLE t2(yy YEAR(2), c2 CHAR(4));
|
||||
CREATE TABLE t4(yyyy YEAR(4), c4 CHAR(4));
|
||||
INSERT INTO t2 (c2) VALUES (NULL),(1970),(1999),(2000),(2001),(2069);
|
||||
INSERT INTO t4 (c4) SELECT c2 FROM t2;
|
||||
UPDATE t2 SET yy = c2;
|
||||
UPDATE t4 SET yyyy = c4;
|
||||
SELECT * FROM t2;
|
||||
yy c2
|
||||
NULL NULL
|
||||
70 1970
|
||||
99 1999
|
||||
00 2000
|
||||
01 2001
|
||||
69 2069
|
||||
SELECT * FROM t4;
|
||||
yyyy c4
|
||||
NULL NULL
|
||||
1970 1970
|
||||
1999 1999
|
||||
2000 2000
|
||||
2001 2001
|
||||
2069 2069
|
||||
# Comparison of YEAR(2) with YEAR(4)
|
||||
SELECT * FROM t2, t4 WHERE yy = yyyy;
|
||||
yy c2 yyyy c4
|
||||
70 1970 1970 1970
|
||||
99 1999 1999 1999
|
||||
00 2000 2000 2000
|
||||
01 2001 2001 2001
|
||||
69 2069 2069 2069
|
||||
SELECT * FROM t2, t4 WHERE yy <=> yyyy;
|
||||
yy c2 yyyy c4
|
||||
NULL NULL NULL NULL
|
||||
70 1970 1970 1970
|
||||
99 1999 1999 1999
|
||||
00 2000 2000 2000
|
||||
01 2001 2001 2001
|
||||
69 2069 2069 2069
|
||||
SELECT * FROM t2, t4 WHERE yy < yyyy;
|
||||
yy c2 yyyy c4
|
||||
70 1970 1999 1999
|
||||
70 1970 2000 2000
|
||||
99 1999 2000 2000
|
||||
70 1970 2001 2001
|
||||
99 1999 2001 2001
|
||||
00 2000 2001 2001
|
||||
70 1970 2069 2069
|
||||
99 1999 2069 2069
|
||||
00 2000 2069 2069
|
||||
01 2001 2069 2069
|
||||
SELECT * FROM t2, t4 WHERE yy > yyyy;
|
||||
yy c2 yyyy c4
|
||||
99 1999 1970 1970
|
||||
00 2000 1970 1970
|
||||
01 2001 1970 1970
|
||||
69 2069 1970 1970
|
||||
00 2000 1999 1999
|
||||
01 2001 1999 1999
|
||||
69 2069 1999 1999
|
||||
01 2001 2000 2000
|
||||
69 2069 2000 2000
|
||||
69 2069 2001 2001
|
||||
# Comparison of YEAR(2) with YEAR(2)
|
||||
SELECT * FROM t2 a, t2 b WHERE a.yy = b.yy;
|
||||
yy c2 yy c2
|
||||
70 1970 70 1970
|
||||
99 1999 99 1999
|
||||
00 2000 00 2000
|
||||
01 2001 01 2001
|
||||
69 2069 69 2069
|
||||
SELECT * FROM t2 a, t2 b WHERE a.yy <=> b.yy;
|
||||
yy c2 yy c2
|
||||
NULL NULL NULL NULL
|
||||
70 1970 70 1970
|
||||
99 1999 99 1999
|
||||
00 2000 00 2000
|
||||
01 2001 01 2001
|
||||
69 2069 69 2069
|
||||
SELECT * FROM t2 a, t2 b WHERE a.yy < b.yy;
|
||||
yy c2 yy c2
|
||||
70 1970 99 1999
|
||||
70 1970 00 2000
|
||||
99 1999 00 2000
|
||||
70 1970 01 2001
|
||||
99 1999 01 2001
|
||||
00 2000 01 2001
|
||||
70 1970 69 2069
|
||||
99 1999 69 2069
|
||||
00 2000 69 2069
|
||||
01 2001 69 2069
|
||||
# Comparison of YEAR(4) with YEAR(4)
|
||||
SELECT * FROM t4 a, t4 b WHERE a.yyyy = b.yyyy;
|
||||
yyyy c4 yyyy c4
|
||||
1970 1970 1970 1970
|
||||
1999 1999 1999 1999
|
||||
2000 2000 2000 2000
|
||||
2001 2001 2001 2001
|
||||
2069 2069 2069 2069
|
||||
SELECT * FROM t4 a, t4 b WHERE a.yyyy <=> b.yyyy;
|
||||
yyyy c4 yyyy c4
|
||||
NULL NULL NULL NULL
|
||||
1970 1970 1970 1970
|
||||
1999 1999 1999 1999
|
||||
2000 2000 2000 2000
|
||||
2001 2001 2001 2001
|
||||
2069 2069 2069 2069
|
||||
SELECT * FROM t4 a, t4 b WHERE a.yyyy < b.yyyy;
|
||||
yyyy c4 yyyy c4
|
||||
1970 1970 1999 1999
|
||||
1970 1970 2000 2000
|
||||
1999 1999 2000 2000
|
||||
1970 1970 2001 2001
|
||||
1999 1999 2001 2001
|
||||
2000 2000 2001 2001
|
||||
1970 1970 2069 2069
|
||||
1999 1999 2069 2069
|
||||
2000 2000 2069 2069
|
||||
2001 2001 2069 2069
|
||||
# Comparison with constants:
|
||||
SELECT * FROM t2 WHERE yy = NULL;
|
||||
yy c2
|
||||
SELECT * FROM t4 WHERE yyyy = NULL;
|
||||
yyyy c4
|
||||
SELECT * FROM t2 WHERE yy <=> NULL;
|
||||
yy c2
|
||||
NULL NULL
|
||||
SELECT * FROM t4 WHERE yyyy <=> NULL;
|
||||
yyyy c4
|
||||
NULL NULL
|
||||
SELECT * FROM t2 WHERE yy < NULL;
|
||||
yy c2
|
||||
SELECT * FROM t2 WHERE yy > NULL;
|
||||
yy c2
|
||||
SELECT * FROM t2 WHERE yy = NOW();
|
||||
yy c2
|
||||
SELECT * FROM t4 WHERE yyyy = NOW();
|
||||
yyyy c4
|
||||
SELECT * FROM t2 WHERE yy = 99;
|
||||
yy c2
|
||||
99 1999
|
||||
SELECT * FROM t2 WHERE 99 = yy;
|
||||
yy c2
|
||||
99 1999
|
||||
SELECT * FROM t4 WHERE yyyy = 99;
|
||||
yyyy c4
|
||||
1999 1999
|
||||
SELECT * FROM t2 WHERE yy = 'test';
|
||||
yy c2
|
||||
00 2000
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect DOUBLE value: 'test'
|
||||
SELECT * FROM t4 WHERE yyyy = 'test';
|
||||
yyyy c4
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect DOUBLE value: 'test'
|
||||
SELECT * FROM t2 WHERE yy = '1999';
|
||||
yy c2
|
||||
99 1999
|
||||
SELECT * FROM t4 WHERE yyyy = '1999';
|
||||
yyyy c4
|
||||
1999 1999
|
||||
SELECT * FROM t2 WHERE yy = 1999;
|
||||
yy c2
|
||||
99 1999
|
||||
SELECT * FROM t4 WHERE yyyy = 1999;
|
||||
yyyy c4
|
||||
1999 1999
|
||||
SELECT * FROM t2 WHERE yy = 1999.1;
|
||||
yy c2
|
||||
99 1999
|
||||
SELECT * FROM t4 WHERE yyyy = 1999.1;
|
||||
yyyy c4
|
||||
1999 1999
|
||||
SELECT * FROM t2 WHERE yy = 1998.9;
|
||||
yy c2
|
||||
99 1999
|
||||
SELECT * FROM t4 WHERE yyyy = 1998.9;
|
||||
yyyy c4
|
||||
1999 1999
|
||||
# Coverage tests for YEAR with zero/2000 constants:
|
||||
SELECT * FROM t2 WHERE yy = 0;
|
||||
yy c2
|
||||
00 2000
|
||||
SELECT * FROM t2 WHERE yy = '0';
|
||||
yy c2
|
||||
00 2000
|
||||
SELECT * FROM t2 WHERE yy = '0000';
|
||||
yy c2
|
||||
00 2000
|
||||
SELECT * FROM t2 WHERE yy = '2000';
|
||||
yy c2
|
||||
00 2000
|
||||
SELECT * FROM t2 WHERE yy = 2000;
|
||||
yy c2
|
||||
00 2000
|
||||
SELECT * FROM t4 WHERE yyyy = 0;
|
||||
yyyy c4
|
||||
SELECT * FROM t4 WHERE yyyy = '0';
|
||||
yyyy c4
|
||||
2000 2000
|
||||
SELECT * FROM t4 WHERE yyyy = '0000';
|
||||
yyyy c4
|
||||
SELECT * FROM t4 WHERE yyyy = '2000';
|
||||
yyyy c4
|
||||
2000 2000
|
||||
SELECT * FROM t4 WHERE yyyy = 2000;
|
||||
yyyy c4
|
||||
2000 2000
|
||||
# Comparison with constants those are out of YEAR range
|
||||
# (coverage test for backward compatibility)
|
||||
SELECT COUNT(yy) FROM t2;
|
||||
COUNT(yy)
|
||||
5
|
||||
SELECT COUNT(yyyy) FROM t4;
|
||||
COUNT(yyyy)
|
||||
5
|
||||
SELECT COUNT(*) FROM t2 WHERE yy = -1;
|
||||
COUNT(*)
|
||||
0
|
||||
SELECT COUNT(*) FROM t4 WHERE yyyy > -1;
|
||||
COUNT(*)
|
||||
5
|
||||
SELECT COUNT(*) FROM t2 WHERE yy > -1000000000000000000;
|
||||
COUNT(*)
|
||||
5
|
||||
SELECT COUNT(*) FROM t4 WHERE yyyy > -1000000000000000000;
|
||||
COUNT(*)
|
||||
5
|
||||
SELECT COUNT(*) FROM t2 WHERE yy < 2156;
|
||||
COUNT(*)
|
||||
5
|
||||
SELECT COUNT(*) FROM t4 WHERE yyyy < 2156;
|
||||
COUNT(*)
|
||||
5
|
||||
SELECT COUNT(*) FROM t2 WHERE yy < 1000000000000000000;
|
||||
COUNT(*)
|
||||
5
|
||||
SELECT COUNT(*) FROM t4 WHERE yyyy < 1000000000000000000;
|
||||
COUNT(*)
|
||||
5
|
||||
SELECT * FROM t2 WHERE yy < 123;
|
||||
yy c2
|
||||
70 1970
|
||||
99 1999
|
||||
00 2000
|
||||
01 2001
|
||||
69 2069
|
||||
SELECT * FROM t2 WHERE yy > 123;
|
||||
yy c2
|
||||
SELECT * FROM t4 WHERE yyyy < 123;
|
||||
yyyy c4
|
||||
SELECT * FROM t4 WHERE yyyy > 123;
|
||||
yyyy c4
|
||||
1970 1970
|
||||
1999 1999
|
||||
2000 2000
|
||||
2001 2001
|
||||
2069 2069
|
||||
DROP TABLE t2, t4;
|
||||
#
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -38,8 +38,6 @@ ERROR HY000: Can't initialize function 'reverse_lookup'; Wrong number of argumen
|
|||
select reverse_lookup("127.0.0.1");
|
||||
select reverse_lookup(127,0,0,1);
|
||||
select reverse_lookup("localhost");
|
||||
reverse_lookup("localhost")
|
||||
NULL
|
||||
select avgcost();
|
||||
ERROR HY000: Can't initialize function 'avgcost'; wrong number of arguments: AVGCOST() requires two arguments
|
||||
select avgcost(100,23.76);
|
||||
|
@ -311,29 +309,6 @@ drop function f3;
|
|||
drop function metaphon;
|
||||
drop function myfunc_double;
|
||||
drop function myfunc_int;
|
||||
CREATE FUNCTION metaphon RETURNS STRING SONAME "UDF_EXAMPLE_LIB";
|
||||
create table t1 (a char);
|
||||
set GLOBAL query_cache_size=1355776;
|
||||
reset query cache;
|
||||
select metaphon('MySQL') from t1;
|
||||
metaphon('MySQL')
|
||||
show status like "Qcache_hits";
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
select metaphon('MySQL') from t1;
|
||||
metaphon('MySQL')
|
||||
show status like "Qcache_hits";
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
drop table t1;
|
||||
drop function metaphon;
|
||||
set GLOBAL query_cache_size=default;
|
||||
DROP DATABASE IF EXISTS mysqltest;
|
||||
CREATE DATABASE mysqltest;
|
||||
USE mysqltest;
|
||||
|
|
24
mysql-test/r/udf_query_cache.result
Normal file
24
mysql-test/r/udf_query_cache.result
Normal file
|
@ -0,0 +1,24 @@
|
|||
drop table if exists t1;
|
||||
CREATE FUNCTION metaphon RETURNS STRING SONAME "UDF_EXAMPLE_LIB";
|
||||
create table t1 (a char);
|
||||
set GLOBAL query_cache_size=1355776;
|
||||
reset query cache;
|
||||
select metaphon('MySQL') from t1;
|
||||
metaphon('MySQL')
|
||||
show status like "Qcache_hits";
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
select metaphon('MySQL') from t1;
|
||||
metaphon('MySQL')
|
||||
show status like "Qcache_hits";
|
||||
Variable_name Value
|
||||
Qcache_hits 0
|
||||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
drop table t1;
|
||||
drop function metaphon;
|
||||
set GLOBAL query_cache_size=default;
|
|
@ -19,8 +19,6 @@ set @my_myisam_max_sort_file_size =@@global.myisam_max_sort_file_size;
|
|||
set @my_net_buffer_length =@@global.net_buffer_length;
|
||||
set @my_net_write_timeout =@@global.net_write_timeout;
|
||||
set @my_net_read_timeout =@@global.net_read_timeout;
|
||||
set @my_query_cache_limit =@@global.query_cache_limit;
|
||||
set @my_query_cache_type =@@global.query_cache_type;
|
||||
set @my_rpl_recovery_rank =@@global.rpl_recovery_rank;
|
||||
set @my_server_id =@@global.server_id;
|
||||
set @my_slow_launch_time =@@global.slow_launch_time;
|
||||
|
@ -215,7 +213,6 @@ storage_engine MRG_MYISAM
|
|||
select * from information_schema.global_variables where variable_name like 'storage_engine';
|
||||
VARIABLE_NAME VARIABLE_VALUE
|
||||
STORAGE_ENGINE MRG_MYISAM
|
||||
set GLOBAL query_cache_size=100000;
|
||||
set GLOBAL myisam_max_sort_file_size=2000000;
|
||||
show global variables like 'myisam_max_sort_file_size';
|
||||
Variable_name Value
|
||||
|
@ -423,8 +420,6 @@ ERROR 42000: Variable 'big_tables' can't be set to the value of '2'
|
|||
show local variables like 'storage_engine';
|
||||
Variable_name Value
|
||||
storage_engine MEMORY
|
||||
set SESSION query_cache_size=10000;
|
||||
ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL
|
||||
set GLOBAL storage_engine=DEFAULT;
|
||||
ERROR 42000: Variable 'storage_engine' doesn't have a default value
|
||||
set character_set_client=UNKNOWN_CHARACTER_SET;
|
||||
|
@ -529,9 +524,6 @@ Warnings:
|
|||
Warning 1292 Truncated incorrect net_buffer_length value: '100'
|
||||
set net_read_timeout=100;
|
||||
set net_write_timeout=100;
|
||||
set global query_cache_limit=100;
|
||||
set global query_cache_size=100;
|
||||
set global query_cache_type=demand;
|
||||
set read_buffer_size=100;
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect read_buffer_size value: '100'
|
||||
|
@ -1047,8 +1039,6 @@ set global myisam_max_sort_file_size =@my_myisam_max_sort_file_size;
|
|||
set global net_buffer_length =@my_net_buffer_length;
|
||||
set global net_write_timeout =@my_net_write_timeout;
|
||||
set global net_read_timeout =@my_net_read_timeout;
|
||||
set global query_cache_limit =@my_query_cache_limit;
|
||||
set global query_cache_type =@my_query_cache_type;
|
||||
set global rpl_recovery_rank =@my_rpl_recovery_rank;
|
||||
set global server_id =@my_server_id;
|
||||
set global slow_launch_time =@my_slow_launch_time;
|
||||
|
|
BIN
mysql-test/std_data/bug47012.ARM
Normal file
BIN
mysql-test/std_data/bug47012.ARM
Normal file
Binary file not shown.
BIN
mysql-test/std_data/bug47012.ARZ
Normal file
BIN
mysql-test/std_data/bug47012.ARZ
Normal file
Binary file not shown.
BIN
mysql-test/std_data/bug47012.frm
Normal file
BIN
mysql-test/std_data/bug47012.frm
Normal file
Binary file not shown.
|
@ -1,17 +1,19 @@
|
|||
-----BEGIN CERTIFICATE-----
|
||||
MIICrTCCAhagAwIBAgIJAJXpePU0UOTVMA0GCSqGSIb3DQEBBQUAMEQxCzAJBgNV
|
||||
BAYTAlNFMRAwDgYDVQQIEwdVcHBzYWxhMRAwDgYDVQQHEwdVcHBzYWxhMREwDwYD
|
||||
VQQKEwhNeVNRTCBBQjAeFw0wOTAxMjgxMDQ5NDZaFw0xNDAxMjcxMDQ5NDZaMEQx
|
||||
CzAJBgNVBAYTAlNFMRAwDgYDVQQIEwdVcHBzYWxhMRAwDgYDVQQHEwdVcHBzYWxh
|
||||
MREwDwYDVQQKEwhNeVNRTCBBQjCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEA
|
||||
4XQHAe5R1+TXC8noZtWf+d5E0v1C59FWpn9SWEUCBjE5UiIwuJvi4Y+7xWGOXLAI
|
||||
/JzJx5gNXLBiTsE/zh0uX9fKlajLhxB0GN+QU0ZlpQ1BeYipEcNXeI/7cT499f6v
|
||||
XWabnTflivdCgHSWUOQ20/Lzs6kP6/e6OoZd/DPSjPECAwEAAaOBpjCBozAdBgNV
|
||||
HQ4EFgQU8uLqVWWkmuKsnZf1RWz294wRrd8wdAYDVR0jBG0wa4AU8uLqVWWkmuKs
|
||||
nZf1RWz294wRrd+hSKRGMEQxCzAJBgNVBAYTAlNFMRAwDgYDVQQIEwdVcHBzYWxh
|
||||
MRAwDgYDVQQHEwdVcHBzYWxhMREwDwYDVQQKEwhNeVNRTCBBQoIJAJXpePU0UOTV
|
||||
MAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADgYEAMMTE5sDN+Z0ZlV7KvH3g
|
||||
6+aKvql8dTpRT3hYukeQlWua0nq74WPGVw0c4e/M/vbiMwmJcCYpB9pd4+dHqzSw
|
||||
aPyoenjY6UF8n7B4quWy3SIUk2LSHeJLW+kzJn2afN9gvipFhdVh/uU2TIyLGOur
|
||||
Z/vmJX2W7hF1uqPnbfa8Lrw=
|
||||
MIIDIjCCAougAwIBAgIJAJhuvLP+2mGwMA0GCSqGSIb3DQEBBQUAMGoxCzAJBgNV
|
||||
BAYTAkZJMRAwDgYDVQQIEwdUdXVzdWxhMRkwFwYDVQQKExBNb250eSBQcm9ncmFt
|
||||
IEFiMS4wLAYJKoZIhvcNAQkBFh9hYnN0cmFjdC5kZXZlbG9wZXJAYXNrbW9udHku
|
||||
b3JnMB4XDTEwMDEyODIxNTcyNVoXDTEwMDIyNzIxNTcyNVowajELMAkGA1UEBhMC
|
||||
RkkxEDAOBgNVBAgTB1R1dXN1bGExGTAXBgNVBAoTEE1vbnR5IFByb2dyYW0gQWIx
|
||||
LjAsBgkqhkiG9w0BCQEWH2Fic3RyYWN0LmRldmVsb3BlckBhc2ttb250eS5vcmcw
|
||||
gZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAMIaY4pwbst50S32xJH3bSXhPGep
|
||||
6gx1AWwZKsHTXL3VeMO6PHmC8zu5HM0zbOcrIJcXL3YVnpmE4b9OQxIiMSx1Yd+U
|
||||
u8/sTkxgpsEKhCbIzECIwPhppyT/JP5aSXCadEvg+PSjikv8dOVkD68wVG4CcFIX
|
||||
MFttsPebBVzEokZZAgMBAAGjgc8wgcwwHQYDVR0OBBYEFOCKaNHFFPrju8AwzWxS
|
||||
f96IKfRwMIGcBgNVHSMEgZQwgZGAFOCKaNHFFPrju8AwzWxSf96IKfRwoW6kbDBq
|
||||
MQswCQYDVQQGEwJGSTEQMA4GA1UECBMHVHV1c3VsYTEZMBcGA1UEChMQTW9udHkg
|
||||
UHJvZ3JhbSBBYjEuMCwGCSqGSIb3DQEJARYfYWJzdHJhY3QuZGV2ZWxvcGVyQGFz
|
||||
a21vbnR5Lm9yZ4IJAJhuvLP+2mGwMAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEF
|
||||
BQADgYEAsmCX2/k9AInq2qhXtnkLip6cB0iOerLTNAzEijZc/aVf4wUjkL3cqhmC
|
||||
kSTCwAHIOxp+ICwh6ky3xghXjoI9QnPFDVkRkzPT2tV0IoBaeQuI4e0CU2EY7L3P
|
||||
XoDqp3oq1XtVcr9ZZdP68fBYUG/qcrWcXWk45ZFaBmBv3TotsGk=
|
||||
-----END CERTIFICATE-----
|
||||
|
|
|
@ -1,55 +1,60 @@
|
|||
Certificate:
|
||||
Data:
|
||||
Version: 3 (0x2)
|
||||
Serial Number: 3 (0x3)
|
||||
Serial Number: 2 (0x2)
|
||||
Signature Algorithm: sha1WithRSAEncryption
|
||||
Issuer: C=SE, ST=Uppsala, L=Uppsala, O=MySQL AB
|
||||
Issuer: C=FI, ST=Tuusula, O=Monty Program Ab/emailAddress=abstract.developer@askmonty.org
|
||||
Validity
|
||||
Not Before: Jan 28 11:04:39 2009 GMT
|
||||
Not After : Jan 28 11:04:39 2010 GMT
|
||||
Subject: C=SE, ST=Uppsala, O=MySQL AB/emailAddress=abstract.mysql.developer@mysql.com
|
||||
Not Before: Jan 28 22:01:38 2010 GMT
|
||||
Not After : Dec 7 22:01:38 2019 GMT
|
||||
Subject: C=FI, ST=Tuusula, O=Monty Program Ab/emailAddress=abstract.developer@askmonty.org
|
||||
Subject Public Key Info:
|
||||
Public Key Algorithm: rsaEncryption
|
||||
RSA Public Key: (512 bit)
|
||||
Modulus (512 bit):
|
||||
00:e1:52:30:2c:d9:be:64:28:91:5d:7a:fd:d9:e9:
|
||||
14:35:7a:d2:94:4e:91:46:e0:db:9f:6b:79:f4:4c:
|
||||
ac:6e:07:61:34:86:74:62:a7:a8:44:af:fa:87:87:
|
||||
a8:7d:42:61:ff:ab:50:d4:7b:bf:75:fa:d5:d5:b3:
|
||||
74:fb:56:1e:37
|
||||
RSA Public Key: (1024 bit)
|
||||
Modulus (1024 bit):
|
||||
00:bd:dc:3d:f8:3c:0b:d4:d2:c0:a3:9c:34:2d:e7:
|
||||
11:ff:4d:43:35:17:f6:0d:91:01:92:9e:4f:4d:c0:
|
||||
38:d5:62:03:55:33:db:66:a2:91:d3:f2:b6:23:34:
|
||||
95:53:50:3d:4f:e3:0c:d7:76:fd:f6:54:64:e6:f6:
|
||||
dc:70:74:7c:6b:74:41:59:b0:19:5d:62:90:3c:a7:
|
||||
c8:5e:21:8f:2b:22:6b:c7:43:9b:be:79:84:60:da:
|
||||
16:c9:ce:ee:fd:66:cb:54:81:e2:b5:1c:cf:f9:74:
|
||||
de:38:2b:28:d4:31:33:55:d2:30:1c:a3:e4:c2:c7:
|
||||
31:46:43:d5:33:3d:8a:0b:47
|
||||
Exponent: 65537 (0x10001)
|
||||
X509v3 extensions:
|
||||
X509v3 Basic Constraints:
|
||||
CA:FALSE
|
||||
Netscape Comment:
|
||||
OpenSSL Generated Certificate
|
||||
X509v3 Subject Key Identifier:
|
||||
58:30:B5:9B:2C:05:94:06:BA:3D:3C:F0:B2:CD:1D:67:65:E3:7F:85
|
||||
BE:E6:DB:19:8D:DB:72:9A:85:EE:B2:B8:5D:E7:FF:61:DF:09:08:AF
|
||||
X509v3 Authority Key Identifier:
|
||||
keyid:F2:E2:EA:55:65:A4:9A:E2:AC:9D:97:F5:45:6C:F6:F7:8C:11:AD:DF
|
||||
DirName:/C=SE/ST=Uppsala/L=Uppsala/O=MySQL AB
|
||||
serial:95:E9:78:F5:34:50:E4:D5
|
||||
keyid:E0:8A:68:D1:C5:14:FA:E3:BB:C0:30:CD:6C:52:7F:DE:88:29:F4:70
|
||||
|
||||
Signature Algorithm: sha1WithRSAEncryption
|
||||
05:19:e3:13:14:fc:c5:28:bf:69:f8:00:b3:25:cb:bd:ca:9f:
|
||||
2f:4c:b3:a8:04:11:f0:74:27:bd:82:2c:b4:49:9b:a7:59:f0:
|
||||
f7:87:d1:e0:ba:99:a2:fe:4b:1d:10:6f:e4:a2:b3:cd:7f:8b:
|
||||
68:31:46:ee:cd:9e:e2:47:e1:4c:fa:74:d1:e2:8b:cc:a0:4b:
|
||||
a8:24:d1:a4:c3:6b:2a:c6:28:cd:41:e0:06:48:e6:cf:f2:3c:
|
||||
ca:37:95:d7:29:64:6b:91:91:83:e7:ac:c8:0b:87:bc:da:a6:
|
||||
aa:f1:44:43:c8:74:7b:15:26:91:2e:03:c4:71:50:6c:f8:68:
|
||||
dc:8c
|
||||
41:95:6d:0a:a4:ee:af:68:cd:94:26:59:9a:18:b7:75:3c:c5:
|
||||
0f:22:d3:5c:31:9b:85:a0:93:b3:f0:50:29:ba:1e:d3:5a:43:
|
||||
0b:77:2d:98:87:a7:a7:39:0f:40:8d:03:d3:b3:67:43:77:bc:
|
||||
3c:51:c2:f9:9e:7a:2d:39:c4:5c:16:d7:70:d6:74:d1:6c:e1:
|
||||
6a:4d:fd:1f:10:af:64:3b:f4:64:e9:b2:b3:fb:c8:cd:c5:41:
|
||||
cd:99:e0:ac:83:1d:81:2c:6b:99:ba:80:02:12:72:f7:3b:bb:
|
||||
93:72:00:da:ff:d3:87:75:d2:3a:a4:ca:4d:c1:8b:c1:21:50:
|
||||
cb:57
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIICfzCCAeigAwIBAgIBAzANBgkqhkiG9w0BAQUFADBEMQswCQYDVQQGEwJTRTEQ
|
||||
MA4GA1UECBMHVXBwc2FsYTEQMA4GA1UEBxMHVXBwc2FsYTERMA8GA1UEChMITXlT
|
||||
UUwgQUIwHhcNMDkwMTI4MTEwNDM5WhcNMTAwMTI4MTEwNDM5WjBlMQswCQYDVQQG
|
||||
EwJTRTEQMA4GA1UECBMHVXBwc2FsYTERMA8GA1UEChMITXlTUUwgQUIxMTAvBgkq
|
||||
hkiG9w0BCQEWImFic3RyYWN0Lm15c3FsLmRldmVsb3BlckBteXNxbC5jb20wXDAN
|
||||
BgkqhkiG9w0BAQEFAANLADBIAkEA4VIwLNm+ZCiRXXr92ekUNXrSlE6RRuDbn2t5
|
||||
9EysbgdhNIZ0YqeoRK/6h4eofUJh/6tQ1Hu/dfrV1bN0+1YeNwIDAQABo4GjMIGg
|
||||
MAkGA1UdEwQCMAAwHQYDVR0OBBYEFFgwtZssBZQGuj088LLNHWdl43+FMHQGA1Ud
|
||||
IwRtMGuAFPLi6lVlpJrirJ2X9UVs9veMEa3foUikRjBEMQswCQYDVQQGEwJTRTEQ
|
||||
MA4GA1UECBMHVXBwc2FsYTEQMA4GA1UEBxMHVXBwc2FsYTERMA8GA1UEChMITXlT
|
||||
UUwgQUKCCQCV6Xj1NFDk1TANBgkqhkiG9w0BAQUFAAOBgQAFGeMTFPzFKL9p+ACz
|
||||
Jcu9yp8vTLOoBBHwdCe9giy0SZunWfD3h9Hgupmi/ksdEG/korPNf4toMUbuzZ7i
|
||||
R+FM+nTR4ovMoEuoJNGkw2sqxijNQeAGSObP8jzKN5XXKWRrkZGD56zIC4e82qaq
|
||||
8URDyHR7FSaRLgPEcVBs+GjcjA==
|
||||
MIICxTCCAi6gAwIBAgIBAjANBgkqhkiG9w0BAQUFADBqMQswCQYDVQQGEwJGSTEQ
|
||||
MA4GA1UECBMHVHV1c3VsYTEZMBcGA1UEChMQTW9udHkgUHJvZ3JhbSBBYjEuMCwG
|
||||
CSqGSIb3DQEJARYfYWJzdHJhY3QuZGV2ZWxvcGVyQGFza21vbnR5Lm9yZzAeFw0x
|
||||
MDAxMjgyMjAxMzhaFw0xOTEyMDcyMjAxMzhaMGoxCzAJBgNVBAYTAkZJMRAwDgYD
|
||||
VQQIEwdUdXVzdWxhMRkwFwYDVQQKExBNb250eSBQcm9ncmFtIEFiMS4wLAYJKoZI
|
||||
hvcNAQkBFh9hYnN0cmFjdC5kZXZlbG9wZXJAYXNrbW9udHkub3JnMIGfMA0GCSqG
|
||||
SIb3DQEBAQUAA4GNADCBiQKBgQC93D34PAvU0sCjnDQt5xH/TUM1F/YNkQGSnk9N
|
||||
wDjVYgNVM9tmopHT8rYjNJVTUD1P4wzXdv32VGTm9txwdHxrdEFZsBldYpA8p8he
|
||||
IY8rImvHQ5u+eYRg2hbJzu79ZstUgeK1HM/5dN44KyjUMTNV0jAco+TCxzFGQ9Uz
|
||||
PYoLRwIDAQABo3sweTAJBgNVHRMEAjAAMCwGCWCGSAGG+EIBDQQfFh1PcGVuU1NM
|
||||
IEdlbmVyYXRlZCBDZXJ0aWZpY2F0ZTAdBgNVHQ4EFgQUvubbGY3bcpqF7rK4Xef/
|
||||
Yd8JCK8wHwYDVR0jBBgwFoAU4Ipo0cUU+uO7wDDNbFJ/3ogp9HAwDQYJKoZIhvcN
|
||||
AQEFBQADgYEAQZVtCqTur2jNlCZZmhi3dTzFDyLTXDGbhaCTs/BQKboe01pDC3ct
|
||||
mIenpzkPQI0D07NnQ3e8PFHC+Z56LTnEXBbXcNZ00Wzhak39HxCvZDv0ZOmys/vI
|
||||
zcVBzZngrIMdgSxrmbqAAhJy9zu7k3IA2v/Th3XSOqTKTcGLwSFQy1c=
|
||||
-----END CERTIFICATE-----
|
||||
|
|
|
@ -1,9 +1,15 @@
|
|||
-----BEGIN RSA PRIVATE KEY-----
|
||||
MIIBOQIBAAJBAOFSMCzZvmQokV16/dnpFDV60pROkUbg259refRMrG4HYTSGdGKn
|
||||
qESv+oeHqH1CYf+rUNR7v3X61dWzdPtWHjcCAwEAAQJAXYooM8ZlcuEgj+VKU1ee
|
||||
qyEFIMqJJxqcMk+E/nWCM96WxCP3zHNSrqNfSpI3ld7QzMwhdRz+gFLxT2gGNpIw
|
||||
MQIhAPxzM/lDihe67X3ADYtDl9ZjA8Pm430x9sXlcxI17tCZAiEA5H1SyFl4mUee
|
||||
9VnfSC2XGW7lwz72ZygfVX+b7tLWF08CIEh40gzW5MfXM+KLxdea+fXjyursV5ZT
|
||||
R6KcMiKiNQLRAiAcmHqlzFzFgisotai2Fc6VRkXHG7gmzOSvBJt1VjmpDQIge6jf
|
||||
2N7whTdvC4ferB+zUlgWQdyvx1c3T4gnt6PYdaY=
|
||||
MIICXgIBAAKBgQC93D34PAvU0sCjnDQt5xH/TUM1F/YNkQGSnk9NwDjVYgNVM9tm
|
||||
opHT8rYjNJVTUD1P4wzXdv32VGTm9txwdHxrdEFZsBldYpA8p8heIY8rImvHQ5u+
|
||||
eYRg2hbJzu79ZstUgeK1HM/5dN44KyjUMTNV0jAco+TCxzFGQ9UzPYoLRwIDAQAB
|
||||
AoGBAJa2lprPT7UJ99Ho1aL6ota/RnKHKtNqII17DgjyZis9OtgP6kJ3GrvdF6iq
|
||||
vT79my4nVrJTyxYXuGF/5U1/qqNjuPPBE1Xbu1ubQlFv8CT0kKYynQ7Z3ls8fAHC
|
||||
B3VJXnUVlG+GHtUEFFG4FQVX1fn/Sga67ioJ6ivAiBlHKaPBAkEA5f2ToWlj4u9O
|
||||
KgfRkN54wdIp4yu2c40pbhMfKGjGGsBAHk92+qSBpzEmxLcI6Ay+4/QysSR4jYmK
|
||||
jCJuxiTu1QJBANNU3Hx8Il2SF/2BqGLcIh2SHxzKQIT5wAyD2jb+P2cHvbk6pKGR
|
||||
VTmw5bibxXmYMS6J/L2zUF2xtFe+Svwz96sCQEnKYSqBqOWvyBFeLtPfPTlal8vm
|
||||
Q4SxfuBtTCrn6t+8XRYcgt0KGPsunvSwkS/6nuh+eiExxWgMACLUDVyPjv0CQQC4
|
||||
sJJc7LOv6Oy0bWr2swHRrBEqvQsz63zOszCzHPHWHirNxZV5aiT8XT/2XZRwlvRs
|
||||
gsVyGFLk/1fn0vN/g/8vAkEAxUdzUKvC1ZwjzGhgcz2bQU0tEZN4C9jBCiwOI2ud
|
||||
BpAsPG0xAGGL2+hz0B0n88XiTHobiTZ1bg4Z41i4pXx2ZA==
|
||||
-----END RSA PRIVATE KEY-----
|
||||
|
|
|
@ -3,53 +3,59 @@ Certificate:
|
|||
Version: 3 (0x2)
|
||||
Serial Number: 1 (0x1)
|
||||
Signature Algorithm: sha1WithRSAEncryption
|
||||
Issuer: C=SE, ST=Uppsala, L=Uppsala, O=MySQL AB
|
||||
Issuer: C=FI, ST=Tuusula, O=Monty Program Ab/emailAddress=abstract.developer@askmonty.org
|
||||
Validity
|
||||
Not Before: Jan 28 10:55:13 2009 GMT
|
||||
Not After : Jan 28 10:55:13 2010 GMT
|
||||
Subject: C=SE, ST=Uppsala, O=MySQL AB, CN=localhost/emailAddress=abstract.mysql.developer@mysql.com
|
||||
Not Before: Jan 28 21:59:14 2010 GMT
|
||||
Not After : Dec 7 21:59:14 2019 GMT
|
||||
Subject: C=FI, ST=Tuusula, O=Monty Program Ab, CN=localhost/emailAddress=abstract.developer@askmonty.org
|
||||
Subject Public Key Info:
|
||||
Public Key Algorithm: rsaEncryption
|
||||
RSA Public Key: (512 bit)
|
||||
Modulus (512 bit):
|
||||
00:b6:8f:e5:b7:b4:86:83:13:8a:f9:bf:63:cb:64:
|
||||
2d:b9:51:d1:de:ab:7b:45:1f:aa:b5:66:73:13:f9:
|
||||
a6:07:d5:ba:7c:fa:92:bd:37:e2:ad:87:db:3e:b6:
|
||||
6a:12:64:f8:ee:17:e3:15:06:2f:a8:82:68:bf:57:
|
||||
8d:c3:04:98:27
|
||||
RSA Public Key: (1024 bit)
|
||||
Modulus (1024 bit):
|
||||
00:cc:79:74:2a:14:7e:77:06:b0:ec:1b:b6:da:70:
|
||||
4c:4f:0e:94:04:8a:e7:69:f4:4c:9c:67:22:41:56:
|
||||
3a:96:53:9e:95:9d:17:55:80:41:c0:13:d6:94:0f:
|
||||
cd:2c:51:fe:a4:6e:f2:74:d8:5d:3b:3a:80:e3:85:
|
||||
5b:a5:bc:7d:5c:25:55:e5:40:77:fe:f3:cb:5b:cd:
|
||||
da:a5:f4:36:64:30:a2:a0:7f:93:b3:c4:56:75:2a:
|
||||
c0:f7:65:2a:d7:e6:ff:88:25:03:e0:b4:40:2e:74:
|
||||
4c:cb:46:95:73:cb:25:5c:87:0e:ec:0f:5a:19:c2:
|
||||
b6:dc:9e:e8:f0:30:b1:9c:99
|
||||
Exponent: 65537 (0x10001)
|
||||
X509v3 extensions:
|
||||
X509v3 Basic Constraints:
|
||||
CA:FALSE
|
||||
Netscape Comment:
|
||||
OpenSSL Generated Certificate
|
||||
X509v3 Subject Key Identifier:
|
||||
D9:9A:B8:5F:22:EA:04:10:C8:25:7D:82:57:E6:2E:FD:19:29:E7:DA
|
||||
6D:13:3B:40:52:3C:AF:18:EA:33:D1:B7:56:21:1B:05:FE:0B:9E:38
|
||||
X509v3 Authority Key Identifier:
|
||||
keyid:F2:E2:EA:55:65:A4:9A:E2:AC:9D:97:F5:45:6C:F6:F7:8C:11:AD:DF
|
||||
DirName:/C=SE/ST=Uppsala/L=Uppsala/O=MySQL AB
|
||||
serial:95:E9:78:F5:34:50:E4:D5
|
||||
keyid:E0:8A:68:D1:C5:14:FA:E3:BB:C0:30:CD:6C:52:7F:DE:88:29:F4:70
|
||||
|
||||
Signature Algorithm: sha1WithRSAEncryption
|
||||
54:07:2d:21:0b:a5:af:3b:58:23:32:5e:56:7f:ab:58:63:48:
|
||||
91:aa:38:90:89:16:f9:cc:bf:a4:0e:78:2b:9f:c5:1b:58:a6:
|
||||
e6:08:8f:2e:ae:97:03:21:9b:f1:cd:c0:26:8f:1d:d7:28:27:
|
||||
a0:8e:81:09:1b:1c:0f:c9:a5:41:3a:2d:44:3f:9c:fa:87:ff:
|
||||
c8:4c:2b:44:f7:1b:c1:3e:4f:01:7f:e9:26:cc:9f:1c:06:b5:
|
||||
0b:27:d1:10:90:be:93:0c:9c:e7:b0:d1:ea:27:99:4e:06:14:
|
||||
0c:7a:e9:c1:52:c5:33:68:bc:61:0d:db:81:3b:57:48:57:bf:
|
||||
42:9a
|
||||
97:db:65:23:7f:f1:15:3c:1e:83:ac:0e:0a:50:a0:0c:22:b8:
|
||||
45:d4:ca:21:05:47:3b:3d:03:b5:6c:4b:8d:bb:5f:57:c3:c7:
|
||||
4e:71:23:cf:33:a3:7f:a0:3d:bd:58:75:b8:37:22:16:2f:e9:
|
||||
ed:ae:9b:94:29:81:6e:34:79:cf:41:bd:3d:8d:17:d7:22:1c:
|
||||
1b:58:c7:0f:79:13:56:1d:e8:d8:4e:e5:07:3f:79:1b:dd:c4:
|
||||
06:9b:c5:b6:02:34:43:c5:bf:e5:87:ad:f1:c1:8a:f2:be:c2:
|
||||
00:1d:d4:27:1f:87:c8:80:31:ec:6e:97:95:b4:84:40:d1:73:
|
||||
42:71
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIICkzCCAfygAwIBAgIBATANBgkqhkiG9w0BAQUFADBEMQswCQYDVQQGEwJTRTEQ
|
||||
MA4GA1UECBMHVXBwc2FsYTEQMA4GA1UEBxMHVXBwc2FsYTERMA8GA1UEChMITXlT
|
||||
UUwgQUIwHhcNMDkwMTI4MTA1NTEzWhcNMTAwMTI4MTA1NTEzWjB5MQswCQYDVQQG
|
||||
EwJTRTEQMA4GA1UECBMHVXBwc2FsYTERMA8GA1UEChMITXlTUUwgQUIxEjAQBgNV
|
||||
BAMTCWxvY2FsaG9zdDExMC8GCSqGSIb3DQEJARYiYWJzdHJhY3QubXlzcWwuZGV2
|
||||
ZWxvcGVyQG15c3FsLmNvbTBcMA0GCSqGSIb3DQEBAQUAA0sAMEgCQQC2j+W3tIaD
|
||||
E4r5v2PLZC25UdHeq3tFH6q1ZnMT+aYH1bp8+pK9N+Kth9s+tmoSZPjuF+MVBi+o
|
||||
gmi/V43DBJgnAgMBAAGjgaMwgaAwCQYDVR0TBAIwADAdBgNVHQ4EFgQU2Zq4XyLq
|
||||
BBDIJX2CV+Yu/Rkp59owdAYDVR0jBG0wa4AU8uLqVWWkmuKsnZf1RWz294wRrd+h
|
||||
SKRGMEQxCzAJBgNVBAYTAlNFMRAwDgYDVQQIEwdVcHBzYWxhMRAwDgYDVQQHEwdV
|
||||
cHBzYWxhMREwDwYDVQQKEwhNeVNRTCBBQoIJAJXpePU0UOTVMA0GCSqGSIb3DQEB
|
||||
BQUAA4GBAFQHLSELpa87WCMyXlZ/q1hjSJGqOJCJFvnMv6QOeCufxRtYpuYIjy6u
|
||||
lwMhm/HNwCaPHdcoJ6COgQkbHA/JpUE6LUQ/nPqH/8hMK0T3G8E+TwF/6SbMnxwG
|
||||
tQsn0RCQvpMMnOew0eonmU4GFAx66cFSxTNovGEN24E7V0hXv0Ka
|
||||
MIIC2TCCAkKgAwIBAgIBATANBgkqhkiG9w0BAQUFADBqMQswCQYDVQQGEwJGSTEQ
|
||||
MA4GA1UECBMHVHV1c3VsYTEZMBcGA1UEChMQTW9udHkgUHJvZ3JhbSBBYjEuMCwG
|
||||
CSqGSIb3DQEJARYfYWJzdHJhY3QuZGV2ZWxvcGVyQGFza21vbnR5Lm9yZzAeFw0x
|
||||
MDAxMjgyMTU5MTRaFw0xOTEyMDcyMTU5MTRaMH4xCzAJBgNVBAYTAkZJMRAwDgYD
|
||||
VQQIEwdUdXVzdWxhMRkwFwYDVQQKExBNb250eSBQcm9ncmFtIEFiMRIwEAYDVQQD
|
||||
Ewlsb2NhbGhvc3QxLjAsBgkqhkiG9w0BCQEWH2Fic3RyYWN0LmRldmVsb3BlckBh
|
||||
c2ttb250eS5vcmcwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAMx5dCoUfncG
|
||||
sOwbttpwTE8OlASK52n0TJxnIkFWOpZTnpWdF1WAQcAT1pQPzSxR/qRu8nTYXTs6
|
||||
gOOFW6W8fVwlVeVAd/7zy1vN2qX0NmQwoqB/k7PEVnUqwPdlKtfm/4glA+C0QC50
|
||||
TMtGlXPLJVyHDuwPWhnCttye6PAwsZyZAgMBAAGjezB5MAkGA1UdEwQCMAAwLAYJ
|
||||
YIZIAYb4QgENBB8WHU9wZW5TU0wgR2VuZXJhdGVkIENlcnRpZmljYXRlMB0GA1Ud
|
||||
DgQWBBRtEztAUjyvGOoz0bdWIRsF/gueODAfBgNVHSMEGDAWgBTgimjRxRT647vA
|
||||
MM1sUn/eiCn0cDANBgkqhkiG9w0BAQUFAAOBgQCX22Ujf/EVPB6DrA4KUKAMIrhF
|
||||
1MohBUc7PQO1bEuNu19Xw8dOcSPPM6N/oD29WHW4NyIWL+ntrpuUKYFuNHnPQb09
|
||||
jRfXIhwbWMcPeRNWHejYTuUHP3kb3cQGm8W2AjRDxb/lh63xwYryvsIAHdQnH4fI
|
||||
gDHsbpeVtIRA0XNCcQ==
|
||||
-----END CERTIFICATE-----
|
||||
|
|
|
@ -1,9 +1,15 @@
|
|||
-----BEGIN RSA PRIVATE KEY-----
|
||||
MIIBOQIBAAJBALaP5be0hoMTivm/Y8tkLblR0d6re0UfqrVmcxP5pgfVunz6kr03
|
||||
4q2H2z62ahJk+O4X4xUGL6iCaL9XjcMEmCcCAwEAAQJASA5VwgNb0CKHiPm0ntOk
|
||||
hG+54SRX3DmafEy6gRjZIl/bZ/asSLhXUZ+CeohyrQh7BZgYWvykd8pRISL9eKsU
|
||||
GQIhAOXkUrOtP/EtjyqNluEqZdG+RZi/7p61JS3Ce13Myu+LAiEAy0uMlV34AJpM
|
||||
b40FPKqlHxw8DD/Dt1iKhNVAg8+LDVUCIFjv7fbJDbW2VG63/Cj8CAwOukoP5rbL
|
||||
iaicVrHBKrllAiB9+MiaXeopZXNrxDS0jQFYr8Q9yt1aJVFgUkxx4Q9HKQIgZPs0
|
||||
KlF3NNNWw78INaAEkyf0IEssnLMsuoCWw0DIOak=
|
||||
MIICXgIBAAKBgQDMeXQqFH53BrDsG7bacExPDpQEiudp9EycZyJBVjqWU56VnRdV
|
||||
gEHAE9aUD80sUf6kbvJ02F07OoDjhVulvH1cJVXlQHf+88tbzdql9DZkMKKgf5Oz
|
||||
xFZ1KsD3ZSrX5v+IJQPgtEAudEzLRpVzyyVchw7sD1oZwrbcnujwMLGcmQIDAQAB
|
||||
AoGBAMdMYkNZsmJFbVDVOobzCg3Mgc1jrmeBrOKNS8AvUe+QFXRyp3m5B102eOHb
|
||||
/PmD+hU/5qao9UZzoYkiRM/oRq45jrqJEYwWrX007bKK0F9hnErtC1ImM1nBFVhx
|
||||
6+6cr+ShUkvtj8+wJ2d5bIccUzGCUfFR5tb5BnePTXK8IVoBAkEA7WGNxHAVKgjS
|
||||
AzlpHr5fvpivA07hNVJizTwZdWGGYeETilZhkkuMRwREceeohF6ILMf0FTZdFSa/
|
||||
8EeLa3icIQJBANyDKFjynKwWy5pyRSz75mVwrEi+4eTQPsCPNWLkbpbEPwqPLYWJ
|
||||
2VSFkISXF7b7Od48JkQWgiB8/kXqMDEdsXkCQQCzZvj3ryWvoP7nhOoXXBWMPGR4
|
||||
gZLe86bMKVGsTsp7CtnzwRj4sbQQr/7yfvvzHmaYQX4M0gtDQwfolomd7YdBAkEA
|
||||
y24ETuqjNu9grf81aiaJipPDnOjcJOcovSRgr/blPxmUvv0Pld5yLNN7W5a4PgrO
|
||||
fAMpmi7ZpXcqbP17sBQgoQJAWTDFKAmfHPVdDGZuCw4yceP5d+Tv7ABglZUvpPKx
|
||||
kAvGN1WBASUuCQJDOIgzl6gvYX07S5p147i9mv7UBWOpvw==
|
||||
-----END RSA PRIVATE KEY-----
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
CALL mtr.add_suppression("Statement may not be safe to log in statement format.");
|
||||
drop table if exists t1, t2;
|
||||
create table t1 (a int) engine=innodb;
|
||||
create table t2 (a int) engine=myisam;
|
||||
|
@ -224,6 +225,8 @@ create table t0 (n int);
|
|||
insert t0 select * from t1;
|
||||
set autocommit=1;
|
||||
insert into t0 select GET_LOCK("lock1",null);
|
||||
Warnings:
|
||||
Note 1592 Statement may not be safe to log in statement format.
|
||||
set autocommit=0;
|
||||
create table t2 (n int) engine=innodb;
|
||||
insert into t2 values (3);
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue