mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Merge trift2.:/MySQL/M51/mysql-5.1
into trift2.:/MySQL/M51/push-5.1 configure.in: Auto merged mysql-test/t/disabled.def: Auto merged sql/field.cc: Auto merged sql/log_event.cc: Auto merged sql/log_event.h: Auto merged sql/rpl_record.cc: Auto merged sql/rpl_utility.cc: Auto merged sql/rpl_utility.h: Auto merged sql/sql_base.cc: Auto merged sql/sql_cache.cc: Auto merged
This commit is contained in:
@ -352,16 +352,11 @@ static my_bool get_full_path_to_executable(char* path)
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
Look for the tool in the same directory as mysql_upgrade.
|
Look for the tool in the same directory as mysql_upgrade.
|
||||||
|
|
||||||
When running in a not yet installed build the the program
|
|
||||||
will exist but it need to be invoked via it's libtool wrapper.
|
|
||||||
Check if the found tool can executed and if not look in the
|
|
||||||
directory one step higher up where the libtool wrapper normally
|
|
||||||
is found
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
static void find_tool(char *tool_path, const char *tool_name)
|
static void find_tool(char *tool_path, const char *tool_name)
|
||||||
{
|
{
|
||||||
|
size_t path_len;
|
||||||
char path[FN_REFLEN];
|
char path[FN_REFLEN];
|
||||||
DYNAMIC_STRING ds_tmp;
|
DYNAMIC_STRING ds_tmp;
|
||||||
DBUG_ENTER("find_tool");
|
DBUG_ENTER("find_tool");
|
||||||
@ -395,38 +390,52 @@ static void find_tool(char *tool_path, const char *tool_name)
|
|||||||
path[0]= 0;
|
path[0]= 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
do
|
|
||||||
|
DBUG_PRINT("info", ("path: '%s'", path));
|
||||||
|
|
||||||
|
/* Chop off binary name (i.e mysql-upgrade) from path */
|
||||||
|
dirname_part(path, path, &path_len);
|
||||||
|
|
||||||
|
/*
|
||||||
|
When running in a not yet installed build and using libtool,
|
||||||
|
the program(mysql_upgrade) will be in .libs/ and executed
|
||||||
|
through a libtool wrapper in order to use the dynamic libraries
|
||||||
|
from this build. The same must be done for the tools(mysql and
|
||||||
|
mysqlcheck). Thus if path ends in .libs/, step up one directory
|
||||||
|
and execute the tools from there
|
||||||
|
*/
|
||||||
|
path[max(path_len-1, 0)]= 0; /* Chop off last / */
|
||||||
|
if (strncmp(path + dirname_length(path), ".libs", 5) == 0)
|
||||||
{
|
{
|
||||||
size_t path_len;
|
DBUG_PRINT("info", ("Chopping off .libs from '%s'", path));
|
||||||
DBUG_PRINT("enter", ("path: %s", path));
|
|
||||||
|
|
||||||
/* Chop off last char(since it might be a /) */
|
/* Chop off .libs */
|
||||||
path[max((strlen(path)-1), 0)]= 0;
|
|
||||||
|
|
||||||
/* Chop off last dir part */
|
|
||||||
dirname_part(path, path, &path_len);
|
dirname_part(path, path, &path_len);
|
||||||
|
|
||||||
/* Format name of the tool to search for */
|
|
||||||
fn_format(tool_path, tool_name,
|
|
||||||
path, "", MYF(MY_REPLACE_DIR));
|
|
||||||
|
|
||||||
verbose("Looking for '%s' in: %s", tool_name, tool_path);
|
|
||||||
|
|
||||||
/* Make sure the tool exists */
|
|
||||||
if (my_access(tool_path, F_OK) != 0)
|
|
||||||
die("Can't find '%s'", tool_path);
|
|
||||||
|
|
||||||
/*
|
|
||||||
Make sure it can be executed, otherwise try again
|
|
||||||
in higher level directory
|
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
while(run_tool(tool_path,
|
|
||||||
&ds_tmp, /* Get output from command, discard*/
|
|
||||||
"--help",
|
DBUG_PRINT("info", ("path: '%s'", path));
|
||||||
"2>&1",
|
|
||||||
IF_WIN("> NUL", "> /dev/null"),
|
/* Format name of the tool to search for */
|
||||||
NULL));
|
fn_format(tool_path, tool_name,
|
||||||
|
path, "", MYF(MY_REPLACE_DIR));
|
||||||
|
|
||||||
|
verbose("Looking for '%s' in: %s", tool_name, tool_path);
|
||||||
|
|
||||||
|
/* Make sure the tool exists */
|
||||||
|
if (my_access(tool_path, F_OK) != 0)
|
||||||
|
die("Can't find '%s'", tool_path);
|
||||||
|
|
||||||
|
/*
|
||||||
|
Make sure it can be executed
|
||||||
|
*/
|
||||||
|
if (run_tool(tool_path,
|
||||||
|
&ds_tmp, /* Get output from command, discard*/
|
||||||
|
"--help",
|
||||||
|
"2>&1",
|
||||||
|
IF_WIN("> NUL", "> /dev/null"),
|
||||||
|
NULL))
|
||||||
|
die("Can't execute '%s'", tool_path);
|
||||||
|
|
||||||
dynstr_free(&ds_tmp);
|
dynstr_free(&ds_tmp);
|
||||||
|
|
||||||
@ -457,6 +466,7 @@ static int run_query(const char *query, DYNAMIC_STRING *ds_res,
|
|||||||
|
|
||||||
ret= run_tool(mysql_path,
|
ret= run_tool(mysql_path,
|
||||||
ds_res,
|
ds_res,
|
||||||
|
"--no-defaults",
|
||||||
ds_args.str,
|
ds_args.str,
|
||||||
"--database=mysql",
|
"--database=mysql",
|
||||||
"--batch", /* Turns off pager etc. */
|
"--batch", /* Turns off pager etc. */
|
||||||
@ -468,6 +478,7 @@ static int run_query(const char *query, DYNAMIC_STRING *ds_res,
|
|||||||
NULL);
|
NULL);
|
||||||
|
|
||||||
my_close(fd, MYF(0));
|
my_close(fd, MYF(0));
|
||||||
|
my_delete(query_file_path, MYF(0));
|
||||||
|
|
||||||
DBUG_RETURN(ret);
|
DBUG_RETURN(ret);
|
||||||
}
|
}
|
||||||
@ -618,6 +629,7 @@ static int run_mysqlcheck_upgrade(void)
|
|||||||
verbose("Running 'mysqlcheck'...");
|
verbose("Running 'mysqlcheck'...");
|
||||||
return run_tool(mysqlcheck_path,
|
return run_tool(mysqlcheck_path,
|
||||||
NULL, /* Send output from mysqlcheck directly to screen */
|
NULL, /* Send output from mysqlcheck directly to screen */
|
||||||
|
"--no-defaults",
|
||||||
ds_args.str,
|
ds_args.str,
|
||||||
"--check-upgrade",
|
"--check-upgrade",
|
||||||
"--all-databases",
|
"--all-databases",
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -9,6 +9,7 @@
|
|||||||
|
|
||||||
const char* SSLeay_version(int type);
|
const char* SSLeay_version(int type);
|
||||||
|
|
||||||
|
#define SSLEAY_NUMBER_DEFINED
|
||||||
#define SSLEAY_VERSION 0x0900L
|
#define SSLEAY_VERSION 0x0900L
|
||||||
#define SSLEAY_VERSION_NUMBER SSLEAY_VERSION
|
#define SSLEAY_VERSION_NUMBER SSLEAY_VERSION
|
||||||
|
|
||||||
|
1
extra/yassl/include/openssl/des_old.h
Normal file
1
extra/yassl/include/openssl/des_old.h
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* des_old.h for openvn */
|
10
extra/yassl/include/openssl/evp.h
Normal file
10
extra/yassl/include/openssl/evp.h
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
/* evp.h for openSSL */
|
||||||
|
|
||||||
|
#ifndef SSLEAY_NUMBER_DEFINED
|
||||||
|
#define SSLEAY_NUMBER_DEFINED
|
||||||
|
|
||||||
|
/* for OpenVPN */
|
||||||
|
#define SSLEAY_VERSION_NUMBER 0x0090700f
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* SSLEAY_NUMBER_DEFINED */
|
1
extra/yassl/include/openssl/hmac.h
Normal file
1
extra/yassl/include/openssl/hmac.h
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* hmac.h for openvpn */
|
1
extra/yassl/include/openssl/objects.h
Normal file
1
extra/yassl/include/openssl/objects.h
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* objects.h for openvpn */
|
@ -30,6 +30,7 @@
|
|||||||
#define SSL_CTX_new yaSSL_CTX_new
|
#define SSL_CTX_new yaSSL_CTX_new
|
||||||
#define SSL_new yaSSL_new
|
#define SSL_new yaSSL_new
|
||||||
#define SSL_set_fd yaSSL_set_fd
|
#define SSL_set_fd yaSSL_set_fd
|
||||||
|
#define SSL_get_fd yaSSL_get_fd
|
||||||
#define SSL_connect yaSSL_connect
|
#define SSL_connect yaSSL_connect
|
||||||
#define SSL_write yaSSL_write
|
#define SSL_write yaSSL_write
|
||||||
#define SSL_read yaSSL_read
|
#define SSL_read yaSSL_read
|
||||||
@ -91,6 +92,8 @@
|
|||||||
#define SSL_set_rfd yaSSL_set_rfd
|
#define SSL_set_rfd yaSSL_set_rfd
|
||||||
#define SSL_set_wfd yaSSL_set_wfd
|
#define SSL_set_wfd yaSSL_set_wfd
|
||||||
#define SSL_set_shutdown yaSSL_set_shutdown
|
#define SSL_set_shutdown yaSSL_set_shutdown
|
||||||
|
#define SSL_set_quiet_shutdown yaSSL_set_quiet_shutdown
|
||||||
|
#define SSL_get_quiet_shutdown yaSSL_get_quiet_shutdown
|
||||||
#define SSL_want_read yaSSL_want_read
|
#define SSL_want_read yaSSL_want_read
|
||||||
#define SSL_want_write yaSSL_want_write
|
#define SSL_want_write yaSSL_want_write
|
||||||
#define SSL_pending yaSSL_pending
|
#define SSL_pending yaSSL_pending
|
||||||
|
1
extra/yassl/include/openssl/sha.h
Normal file
1
extra/yassl/include/openssl/sha.h
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* sha.h for openvpn */
|
@ -34,7 +34,7 @@
|
|||||||
#include "rsa.h"
|
#include "rsa.h"
|
||||||
|
|
||||||
|
|
||||||
#define YASSL_VERSION "1.6.5"
|
#define YASSL_VERSION "1.7.2"
|
||||||
|
|
||||||
|
|
||||||
#if defined(__cplusplus)
|
#if defined(__cplusplus)
|
||||||
@ -201,6 +201,7 @@ typedef int YASSL_SOCKET_T;
|
|||||||
SSL_CTX* SSL_CTX_new(SSL_METHOD*);
|
SSL_CTX* SSL_CTX_new(SSL_METHOD*);
|
||||||
SSL* SSL_new(SSL_CTX*);
|
SSL* SSL_new(SSL_CTX*);
|
||||||
int SSL_set_fd (SSL*, YASSL_SOCKET_T);
|
int SSL_set_fd (SSL*, YASSL_SOCKET_T);
|
||||||
|
YASSL_SOCKET_T SSL_get_fd(const SSL*);
|
||||||
int SSL_connect(SSL*);
|
int SSL_connect(SSL*);
|
||||||
int SSL_write(SSL*, const void*, int);
|
int SSL_write(SSL*, const void*, int);
|
||||||
int SSL_read(SSL*, void*, int);
|
int SSL_read(SSL*, void*, int);
|
||||||
|
@ -584,7 +584,7 @@ class SSL {
|
|||||||
Socket socket_; // socket wrapper
|
Socket socket_; // socket wrapper
|
||||||
Buffers buffers_; // buffered handshakes and data
|
Buffers buffers_; // buffered handshakes and data
|
||||||
Log log_; // logger
|
Log log_; // logger
|
||||||
bool quietShutdown_; // shutdown without handshakes
|
bool quietShutdown_;
|
||||||
|
|
||||||
// optimization variables
|
// optimization variables
|
||||||
bool has_data_; // buffered data ready?
|
bool has_data_; // buffered data ready?
|
||||||
|
@ -719,6 +719,10 @@ int DoProcessReply(SSL& ssl)
|
|||||||
|
|
||||||
// add new data
|
// add new data
|
||||||
uint read = ssl.useSocket().receive(buffer.get_buffer() + buffSz, ready);
|
uint read = ssl.useSocket().receive(buffer.get_buffer() + buffSz, ready);
|
||||||
|
if (read == static_cast<uint>(-1)) {
|
||||||
|
ssl.SetError(receive_error);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
buffer.add_size(read);
|
buffer.add_size(read);
|
||||||
uint offset = 0;
|
uint offset = 0;
|
||||||
const MessageFactory& mf = ssl.getFactory().getMessage();
|
const MessageFactory& mf = ssl.getFactory().getMessage();
|
||||||
|
@ -114,8 +114,6 @@ uint Socket::send(const byte* buf, unsigned int sz, int flags) const
|
|||||||
const byte* pos = buf;
|
const byte* pos = buf;
|
||||||
const byte* end = pos + sz;
|
const byte* end = pos + sz;
|
||||||
|
|
||||||
assert(socket_ != INVALID_SOCKET);
|
|
||||||
|
|
||||||
while (pos != end) {
|
while (pos != end) {
|
||||||
int sent = ::send(socket_, reinterpret_cast<const char *>(pos),
|
int sent = ::send(socket_, reinterpret_cast<const char *>(pos),
|
||||||
static_cast<int>(end - pos), flags);
|
static_cast<int>(end - pos), flags);
|
||||||
@ -132,7 +130,6 @@ uint Socket::send(const byte* buf, unsigned int sz, int flags) const
|
|||||||
|
|
||||||
uint Socket::receive(byte* buf, unsigned int sz, int flags)
|
uint Socket::receive(byte* buf, unsigned int sz, int flags)
|
||||||
{
|
{
|
||||||
assert(socket_ != INVALID_SOCKET);
|
|
||||||
wouldBlock_ = false;
|
wouldBlock_ = false;
|
||||||
|
|
||||||
int recvd = ::recv(socket_, reinterpret_cast<char *>(buf), sz, flags);
|
int recvd = ::recv(socket_, reinterpret_cast<char *>(buf), sz, flags);
|
||||||
@ -163,7 +160,6 @@ bool Socket::wait()
|
|||||||
|
|
||||||
void Socket::shutDown(int how)
|
void Socket::shutDown(int how)
|
||||||
{
|
{
|
||||||
assert(socket_ != INVALID_SOCKET);
|
|
||||||
shutdown(socket_, how);
|
shutdown(socket_, how);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -239,6 +239,12 @@ int SSL_set_fd(SSL* ssl, YASSL_SOCKET_T fd)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
YASSL_SOCKET_T SSL_get_fd(const SSL* ssl)
|
||||||
|
{
|
||||||
|
return ssl->getSocket().get_fd();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
int SSL_connect(SSL* ssl)
|
int SSL_connect(SSL* ssl)
|
||||||
{
|
{
|
||||||
if (ssl->GetError() == YasslError(SSL_ERROR_WANT_READ))
|
if (ssl->GetError() == YasslError(SSL_ERROR_WANT_READ))
|
||||||
|
@ -773,6 +773,7 @@ void SSL::SetError(YasslError ye)
|
|||||||
// TODO: add string here
|
// TODO: add string here
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// set the quiet shutdown mode (close_nofiy not sent or received on shutdown)
|
// set the quiet shutdown mode (close_nofiy not sent or received on shutdown)
|
||||||
void SSL::SetQuietShutdown(bool mode)
|
void SSL::SetQuietShutdown(bool mode)
|
||||||
{
|
{
|
||||||
|
@ -107,11 +107,12 @@ void HexDecoder::Decode()
|
|||||||
// sanity checks
|
// sanity checks
|
||||||
assert( b < sizeof(hexDecode)/sizeof(hexDecode[0]) );
|
assert( b < sizeof(hexDecode)/sizeof(hexDecode[0]) );
|
||||||
assert( b2 < sizeof(hexDecode)/sizeof(hexDecode[0]) );
|
assert( b2 < sizeof(hexDecode)/sizeof(hexDecode[0]) );
|
||||||
assert( b != bad && b2 != bad );
|
|
||||||
|
|
||||||
b = hexDecode[b];
|
b = hexDecode[b];
|
||||||
b2 = hexDecode[b2];
|
b2 = hexDecode[b2];
|
||||||
|
|
||||||
|
assert( b != bad && b2 != bad );
|
||||||
|
|
||||||
decoded_[i++] = (b << 4) | b2;
|
decoded_[i++] = (b << 4) | b2;
|
||||||
bytes -= 2;
|
bytes -= 2;
|
||||||
}
|
}
|
||||||
@ -184,7 +185,7 @@ void Base64Decoder::Decode()
|
|||||||
{
|
{
|
||||||
word32 bytes = coded_.size();
|
word32 bytes = coded_.size();
|
||||||
word32 plainSz = bytes - ((bytes + (pemLineSz - 1)) / pemLineSz);
|
word32 plainSz = bytes - ((bytes + (pemLineSz - 1)) / pemLineSz);
|
||||||
plainSz = ((plainSz * 3) / 4) + 3;
|
plainSz = (plainSz * 3 + 3) / 4;
|
||||||
decoded_.New(plainSz);
|
decoded_.New(plainSz);
|
||||||
|
|
||||||
word32 i = 0;
|
word32 i = 0;
|
||||||
|
@ -26,6 +26,11 @@ extern "C" {
|
|||||||
// locking handled internally by library
|
// locking handled internally by library
|
||||||
char CRYPTO_lock() { return 0;}
|
char CRYPTO_lock() { return 0;}
|
||||||
char CRYPTO_add_lock() { return 0;}
|
char CRYPTO_add_lock() { return 0;}
|
||||||
|
|
||||||
|
|
||||||
|
// for openvpn, test are the signatures they use
|
||||||
|
char EVP_CIPHER_CTX_init() { return 0; }
|
||||||
|
char CRYPTO_mem_ctrl() { return 0; }
|
||||||
} // extern "C"
|
} // extern "C"
|
||||||
|
|
||||||
|
|
||||||
|
@ -15,18 +15,17 @@
|
|||||||
# Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
# Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||||
# MA 02111-1307, USA
|
# MA 02111-1307, USA
|
||||||
|
|
||||||
# FIXME 'abi_check' should be in BUILT_SOURCES, disabled for now
|
|
||||||
BUILT_SOURCES = $(HEADERS_GEN) link_sources
|
BUILT_SOURCES = $(HEADERS_GEN) link_sources
|
||||||
HEADERS_GEN = mysql_version.h my_config.h
|
HEADERS_GEN = mysql_version.h my_config.h
|
||||||
HEADERS_ABI = mysql.h mysql_com.h mysql_time.h \
|
HEADERS_ABI = mysql.h mysql_com.h mysql_time.h \
|
||||||
my_list.h my_alloc.h typelib.h
|
my_list.h my_alloc.h typelib.h mysql/plugin.h
|
||||||
pkginclude_HEADERS = $(HEADERS_ABI) my_dbug.h m_string.h my_sys.h \
|
pkginclude_HEADERS = $(HEADERS_ABI) my_dbug.h m_string.h my_sys.h \
|
||||||
my_xml.h mysql_embed.h \
|
my_xml.h mysql_embed.h \
|
||||||
my_pthread.h my_no_pthread.h \
|
my_pthread.h my_no_pthread.h \
|
||||||
decimal.h errmsg.h my_global.h my_net.h \
|
decimal.h errmsg.h my_global.h my_net.h \
|
||||||
my_getopt.h sslopt-longopts.h my_dir.h \
|
my_getopt.h sslopt-longopts.h my_dir.h \
|
||||||
sslopt-vars.h sslopt-case.h sql_common.h keycache.h \
|
sslopt-vars.h sslopt-case.h sql_common.h keycache.h \
|
||||||
m_ctype.h mysql/plugin.h my_attribute.h $(HEADERS_GEN)
|
m_ctype.h my_attribute.h $(HEADERS_GEN)
|
||||||
noinst_HEADERS = config-win.h config-netware.h \
|
noinst_HEADERS = config-win.h config-netware.h \
|
||||||
heap.h my_bitmap.h my_uctype.h \
|
heap.h my_bitmap.h my_uctype.h \
|
||||||
myisam.h myisampack.h myisammrg.h ft_global.h\
|
myisam.h myisampack.h myisammrg.h ft_global.h\
|
||||||
@ -72,9 +71,8 @@ dist-hook:
|
|||||||
abi_check: $(HEADERS_ABI) mysql_version.h mysql_h.ic
|
abi_check: $(HEADERS_ABI) mysql_version.h mysql_h.ic
|
||||||
@set -ex; \
|
@set -ex; \
|
||||||
if [ @ICHECK@ != no ] ; then \
|
if [ @ICHECK@ != no ] ; then \
|
||||||
@ICHECK@ --canonify --skip-from-re /usr/ -o $@.ic mysql.h; \
|
@ICHECK@ --canonify --skip-from-re /usr/ -o $@ $(HEADERS_ABI); \
|
||||||
@ICHECK@ --compare mysql_h.ic $@.ic; \
|
@ICHECK@ --compare mysql_h.ic $@; \
|
||||||
$(RM) -f $@.ic; \
|
|
||||||
fi; \
|
fi; \
|
||||||
touch abi_check;
|
touch abi_check;
|
||||||
|
|
||||||
|
1073
include/mysql_h.ic
1073
include/mysql_h.ic
File diff suppressed because it is too large
Load Diff
@ -564,6 +564,17 @@ void init_embedded_mysql(MYSQL *mysql, int client_flag)
|
|||||||
init_alloc_root(&mysql->field_alloc, 8192, 0);
|
init_alloc_root(&mysql->field_alloc, 8192, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
@brief Initialize a new THD for a connection in the embedded server
|
||||||
|
|
||||||
|
@param client_flag Client capabilities which this thread supports
|
||||||
|
@return pointer to the created THD object
|
||||||
|
|
||||||
|
@todo
|
||||||
|
This function copies code from several places in the server, including
|
||||||
|
create_new_thread(), and prepare_new_connection_state(). This should
|
||||||
|
be refactored to avoid code duplication.
|
||||||
|
*/
|
||||||
void *create_embedded_thd(int client_flag)
|
void *create_embedded_thd(int client_flag)
|
||||||
{
|
{
|
||||||
THD * thd= new THD;
|
THD * thd= new THD;
|
||||||
|
119
mysql-test/extra/rpl_tests/rpl_ndb_2multi_basic.test
Normal file
119
mysql-test/extra/rpl_tests/rpl_ndb_2multi_basic.test
Normal file
@ -0,0 +1,119 @@
|
|||||||
|
#######################################
|
||||||
|
# Author: Rafal Somla #
|
||||||
|
# Date: 2006-08-20 #
|
||||||
|
# Purpose: Test replication of basic #
|
||||||
|
# table operations in various setups #
|
||||||
|
# #
|
||||||
|
# Based on rpl_ndb_2multi_eng.test by #
|
||||||
|
# JBM #
|
||||||
|
#######################################
|
||||||
|
|
||||||
|
--echo --- Doing pre test cleanup ---
|
||||||
|
|
||||||
|
connection master;
|
||||||
|
--disable_warnings
|
||||||
|
DROP TABLE IF EXISTS t1;
|
||||||
|
--enable_query_log
|
||||||
|
|
||||||
|
#################################################
|
||||||
|
--echo --- Create Table Section ---
|
||||||
|
|
||||||
|
CREATE TABLE t1 (id MEDIUMINT NOT NULL,
|
||||||
|
b1 INT,
|
||||||
|
vc VARCHAR(255),
|
||||||
|
bc CHAR(255),
|
||||||
|
d DECIMAL(10,4) DEFAULT 0,
|
||||||
|
f FLOAT DEFAULT 0,
|
||||||
|
total BIGINT UNSIGNED,
|
||||||
|
y YEAR,
|
||||||
|
t DATE,
|
||||||
|
PRIMARY KEY(id));
|
||||||
|
|
||||||
|
--echo --- Show table on master ---
|
||||||
|
|
||||||
|
SHOW CREATE TABLE t1;
|
||||||
|
|
||||||
|
--echo --- Show table on slave ---
|
||||||
|
|
||||||
|
sync_slave_with_master;
|
||||||
|
SHOW CREATE TABLE t1;
|
||||||
|
|
||||||
|
--source include/rpl_multi_engine2.inc
|
||||||
|
|
||||||
|
#################################################
|
||||||
|
# Okay lets see how it holds up to table changes
|
||||||
|
--echo --- Check that simple Alter statements are replicated correctly --
|
||||||
|
|
||||||
|
ALTER TABLE t1 DROP PRIMARY KEY;
|
||||||
|
# note: table with no PK can't contain blobs if it is to be replicated.
|
||||||
|
ALTER TABLE t1 MODIFY vc char(32);
|
||||||
|
|
||||||
|
--echo --- Show the new improved table on the master ---
|
||||||
|
|
||||||
|
SHOW CREATE TABLE t1;
|
||||||
|
|
||||||
|
--echo --- Make sure that our tables on slave are still same engine ---
|
||||||
|
--echo --- and that the alter statements replicated correctly ---
|
||||||
|
|
||||||
|
sync_slave_with_master;
|
||||||
|
SHOW CREATE TABLE t1;
|
||||||
|
|
||||||
|
--source include/rpl_multi_engine2.inc
|
||||||
|
|
||||||
|
#################################################
|
||||||
|
--echo --- Check that replication works when slave has more columns than master
|
||||||
|
connection master;
|
||||||
|
ALTER TABLE t1 ADD PRIMARY KEY(id,total);
|
||||||
|
ALTER TABLE t1 MODIFY vc TEXT;
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES(3,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"1905-11-14");
|
||||||
|
INSERT INTO t1 VALUES(20,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"1965-11-14");
|
||||||
|
INSERT INTO t1 VALUES(50,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"1985-11-14");
|
||||||
|
|
||||||
|
--echo --- Add columns on slave ---
|
||||||
|
--sync_slave_with_master
|
||||||
|
ALTER TABLE t1 ADD (u int, v char(16) default 'default');
|
||||||
|
UPDATE t1 SET u=7 WHERE id < 50;
|
||||||
|
UPDATE t1 SET v='explicit' WHERE id >10;
|
||||||
|
|
||||||
|
--echo --- Show changed table on slave ---
|
||||||
|
|
||||||
|
SHOW CREATE TABLE t1;
|
||||||
|
SELECT *
|
||||||
|
FROM t1
|
||||||
|
ORDER BY id;
|
||||||
|
|
||||||
|
--source include/rpl_multi_engine2.inc
|
||||||
|
TRUNCATE TABLE t1;
|
||||||
|
|
||||||
|
#################################################
|
||||||
|
--echo --- Check that replication works when master has more columns than slave
|
||||||
|
connection master;
|
||||||
|
|
||||||
|
--echo --- Remove columns on slave ---
|
||||||
|
--sync_slave_with_master
|
||||||
|
ALTER TABLE t1 DROP COLUMN v;
|
||||||
|
ALTER TABLE t1 DROP COLUMN u;
|
||||||
|
ALTER TABLE t1 DROP COLUMN t;
|
||||||
|
ALTER TABLE t1 DROP COLUMN y;
|
||||||
|
|
||||||
|
--echo --- Show changed table on slave ---
|
||||||
|
|
||||||
|
SHOW CREATE TABLE t1;
|
||||||
|
|
||||||
|
--source include/rpl_multi_engine2.inc
|
||||||
|
TRUNCATE TABLE t1;
|
||||||
|
|
||||||
|
#################################################
|
||||||
|
--echo --- Do Cleanup --
|
||||||
|
connection master;
|
||||||
|
DROP TABLE IF EXISTS t1;
|
||||||
|
|
||||||
|
sync_slave_with_master;
|
||||||
|
connection master;
|
@ -9,5 +9,6 @@ eval SHOW CREATE TABLE t1;
|
|||||||
# listing of files belonging to the table t1
|
# listing of files belonging to the table t1
|
||||||
if ($ls)
|
if ($ls)
|
||||||
{
|
{
|
||||||
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
--exec ls $MYSQLTEST_VARDIR/master-data/test/t1*
|
--exec ls $MYSQLTEST_VARDIR/master-data/test/t1*
|
||||||
}
|
}
|
||||||
|
91
mysql-test/include/rpl_multi_engine2.inc
Normal file
91
mysql-test/include/rpl_multi_engine2.inc
Normal file
@ -0,0 +1,91 @@
|
|||||||
|
#############################################################
|
||||||
|
# Author: Rafal
|
||||||
|
# Date: 2007-08-20
|
||||||
|
# based on rpl_multi_engine3.inc
|
||||||
|
#############################################################
|
||||||
|
|
||||||
|
connection slave;
|
||||||
|
STOP SLAVE;
|
||||||
|
RESET SLAVE;
|
||||||
|
|
||||||
|
connection master;
|
||||||
|
RESET MASTER;
|
||||||
|
|
||||||
|
connection slave;
|
||||||
|
START SLAVE;
|
||||||
|
|
||||||
|
--echo --- Populate t1 with data ---
|
||||||
|
connection master;
|
||||||
|
--disable_query_log
|
||||||
|
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"1905-11-14");
|
||||||
|
INSERT INTO t1 VALUES(2,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"1965-11-14");
|
||||||
|
INSERT INTO t1 VALUES(4,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"1985-11-14");
|
||||||
|
INSERT INTO t1 VALUES(142,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"1995-11-14");
|
||||||
|
INSERT INTO t1 VALUES(412,1,'Testing MySQL databases is a cool ',
|
||||||
|
'Must make it bug free for the customer',
|
||||||
|
654321.4321,15.21,0,1965,"2005-11-14");
|
||||||
|
--enable_query_log
|
||||||
|
|
||||||
|
--echo --- Select from t1 on master ---
|
||||||
|
select *
|
||||||
|
from t1
|
||||||
|
order by id;
|
||||||
|
|
||||||
|
sync_slave_with_master;
|
||||||
|
--echo --- Select from t1 on slave ---
|
||||||
|
select *
|
||||||
|
from t1
|
||||||
|
order by id;
|
||||||
|
|
||||||
|
--echo --- Perform basic operation on master ---
|
||||||
|
--echo --- and ensure replicated correctly ---
|
||||||
|
connection master;
|
||||||
|
|
||||||
|
--echo --- Update t1 on master --
|
||||||
|
UPDATE t1 SET b1 = 0, bc='updated', t="2006-02-22"
|
||||||
|
WHERE id < 100
|
||||||
|
ORDER BY id;
|
||||||
|
|
||||||
|
--echo --- Check the update on master ---
|
||||||
|
SELECT *
|
||||||
|
FROM t1
|
||||||
|
WHERE id < 100
|
||||||
|
ORDER BY id;
|
||||||
|
|
||||||
|
# Must give injector thread a little time to get update
|
||||||
|
# into the binlog other wise we will miss the update.
|
||||||
|
|
||||||
|
sync_slave_with_master;
|
||||||
|
--echo --- Check Update on slave ---
|
||||||
|
SELECT *
|
||||||
|
FROM t1
|
||||||
|
WHERE id < 100
|
||||||
|
ORDER BY id;
|
||||||
|
|
||||||
|
connection master;
|
||||||
|
--echo --- Remove a record from t1 on master ---
|
||||||
|
# Note: there is an error in replication of Delete_row
|
||||||
|
# from NDB to MyISAM (BUG#28538). However, if there is
|
||||||
|
# only one row in Delete_row event then it works fine,
|
||||||
|
# as this test demonstrates.
|
||||||
|
DELETE FROM t1 WHERE id = 412;
|
||||||
|
|
||||||
|
--echo --- Show current count on master for t1 ---
|
||||||
|
SELECT COUNT(*) FROM t1;
|
||||||
|
|
||||||
|
sync_slave_with_master;
|
||||||
|
--echo --- Show current count on slave for t1 ---
|
||||||
|
SELECT COUNT(*) FROM t1;
|
||||||
|
|
||||||
|
connection master;
|
||||||
|
TRUNCATE TABLE t1;
|
||||||
|
sync_slave_with_master;
|
||||||
|
connection master;
|
@ -53,7 +53,8 @@ sub collect_test_cases ($) {
|
|||||||
my $found= 0;
|
my $found= 0;
|
||||||
foreach my $test ( @$cases )
|
foreach my $test ( @$cases )
|
||||||
{
|
{
|
||||||
if ( mtr_match_extension($test->{'name'}, $tname) )
|
if ( $test->{'name'} eq $tname ||
|
||||||
|
mtr_match_extension($test->{'name'}, $tname) )
|
||||||
{
|
{
|
||||||
$found= 1;
|
$found= 1;
|
||||||
}
|
}
|
||||||
@ -192,8 +193,9 @@ sub collect_one_suite($$)
|
|||||||
if ( @::opt_cases )
|
if ( @::opt_cases )
|
||||||
{
|
{
|
||||||
# Collect in specified order, no sort
|
# Collect in specified order, no sort
|
||||||
foreach my $tname ( @::opt_cases )
|
foreach my $tname2 ( @::opt_cases )
|
||||||
{
|
{
|
||||||
|
my $tname= $tname2; # Don't modify @::opt_cases !
|
||||||
my $elem= undef;
|
my $elem= undef;
|
||||||
my $component_id= undef;
|
my $component_id= undef;
|
||||||
|
|
||||||
@ -202,6 +204,9 @@ sub collect_one_suite($$)
|
|||||||
|
|
||||||
$tname = basename($tname);
|
$tname = basename($tname);
|
||||||
|
|
||||||
|
# Get rid of suite part
|
||||||
|
$tname =~ s/^$suite\.//;
|
||||||
|
|
||||||
# Check if the extenstion has been specified.
|
# Check if the extenstion has been specified.
|
||||||
|
|
||||||
if ( mtr_match_extension($tname, "test") )
|
if ( mtr_match_extension($tname, "test") )
|
||||||
|
@ -19,9 +19,8 @@
|
|||||||
# same name.
|
# same name.
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
use File::Find;
|
||||||
|
|
||||||
sub mtr_full_hostname ();
|
|
||||||
sub mtr_short_hostname ();
|
|
||||||
sub mtr_native_path($);
|
sub mtr_native_path($);
|
||||||
sub mtr_init_args ($);
|
sub mtr_init_args ($);
|
||||||
sub mtr_add_arg ($$@);
|
sub mtr_add_arg ($$@);
|
||||||
@ -31,6 +30,7 @@ sub mtr_file_exists(@);
|
|||||||
sub mtr_exe_exists(@);
|
sub mtr_exe_exists(@);
|
||||||
sub mtr_exe_maybe_exists(@);
|
sub mtr_exe_maybe_exists(@);
|
||||||
sub mtr_copy_dir($$);
|
sub mtr_copy_dir($$);
|
||||||
|
sub mtr_rmtree($);
|
||||||
sub mtr_same_opts($$);
|
sub mtr_same_opts($$);
|
||||||
sub mtr_cmp_opts($$);
|
sub mtr_cmp_opts($$);
|
||||||
|
|
||||||
@ -40,30 +40,6 @@ sub mtr_cmp_opts($$);
|
|||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
# We want the fully qualified host name and hostname() may have returned
|
|
||||||
# only the short name. So we use the resolver to find out.
|
|
||||||
# Note that this might fail on some platforms
|
|
||||||
|
|
||||||
sub mtr_full_hostname () {
|
|
||||||
|
|
||||||
my $hostname= hostname();
|
|
||||||
if ( $hostname !~ /\./ )
|
|
||||||
{
|
|
||||||
my $address= gethostbyname($hostname)
|
|
||||||
or mtr_error("Couldn't resolve $hostname : $!");
|
|
||||||
my $fullname= gethostbyaddr($address, AF_INET);
|
|
||||||
$hostname= $fullname if $fullname;
|
|
||||||
}
|
|
||||||
return $hostname;
|
|
||||||
}
|
|
||||||
|
|
||||||
sub mtr_short_hostname () {
|
|
||||||
|
|
||||||
my $hostname= hostname();
|
|
||||||
$hostname =~ s/\..+$//;
|
|
||||||
return $hostname;
|
|
||||||
}
|
|
||||||
|
|
||||||
# Convert path to OS native format
|
# Convert path to OS native format
|
||||||
sub mtr_native_path($)
|
sub mtr_native_path($)
|
||||||
{
|
{
|
||||||
@ -226,6 +202,57 @@ sub mtr_copy_dir($$) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
sub mtr_rmtree($) {
|
||||||
|
my ($dir)= @_;
|
||||||
|
mtr_verbose("mtr_rmtree: $dir");
|
||||||
|
|
||||||
|
# Try to use File::Path::rmtree. Recent versions
|
||||||
|
# handles removal of directories and files that don't
|
||||||
|
# have full permissions, while older versions
|
||||||
|
# may have a problem with that and we use our own version
|
||||||
|
|
||||||
|
eval { rmtree($dir); };
|
||||||
|
if ( $@ ) {
|
||||||
|
mtr_warning("rmtree($dir) failed, trying with File::Find...");
|
||||||
|
|
||||||
|
my $errors= 0;
|
||||||
|
|
||||||
|
# chmod
|
||||||
|
find( {
|
||||||
|
no_chdir => 1,
|
||||||
|
wanted => sub {
|
||||||
|
chmod(0777, $_)
|
||||||
|
or mtr_warning("couldn't chmod(0777, $_): $!") and $errors++;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
$dir
|
||||||
|
);
|
||||||
|
|
||||||
|
# rm
|
||||||
|
finddepth( {
|
||||||
|
no_chdir => 1,
|
||||||
|
wanted => sub {
|
||||||
|
my $file= $_;
|
||||||
|
# Use special underscore (_) filehandle, caches stat info
|
||||||
|
if (!-l $file and -d _ ) {
|
||||||
|
rmdir($file) or
|
||||||
|
mtr_warning("couldn't rmdir($file): $!") and $errors++;
|
||||||
|
} else {
|
||||||
|
unlink($file)
|
||||||
|
or mtr_warning("couldn't unlink($file): $!") and $errors++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
$dir
|
||||||
|
);
|
||||||
|
|
||||||
|
mtr_error("Failed to remove '$dir'") if $errors;
|
||||||
|
|
||||||
|
mtr_report("OK, that worked!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
sub mtr_same_opts ($$) {
|
sub mtr_same_opts ($$) {
|
||||||
my $l1= shift;
|
my $l1= shift;
|
||||||
my $l2= shift;
|
my $l2= shift;
|
||||||
|
@ -99,25 +99,26 @@ sub spawn_impl ($$$$$$$) {
|
|||||||
|
|
||||||
if ( $::opt_script_debug )
|
if ( $::opt_script_debug )
|
||||||
{
|
{
|
||||||
print STDERR "\n";
|
mtr_report("");
|
||||||
print STDERR "#### ", "-" x 78, "\n";
|
mtr_debug("-" x 73);
|
||||||
print STDERR "#### ", "STDIN $input\n" if $input;
|
mtr_debug("STDIN $input") if $input;
|
||||||
print STDERR "#### ", "STDOUT $output\n" if $output;
|
mtr_debug("STDOUT $output") if $output;
|
||||||
print STDERR "#### ", "STDERR $error\n" if $error;
|
mtr_debug("STDERR $error") if $error;
|
||||||
print STDERR "#### ", "$mode : $path ", join(" ",@$arg_list_t), "\n";
|
mtr_debug("$mode: $path ", join(" ",@$arg_list_t));
|
||||||
print STDERR "#### ", "spawn options:\n";
|
mtr_debug("spawn options:");
|
||||||
if ($spawn_opts)
|
if ($spawn_opts)
|
||||||
{
|
{
|
||||||
foreach my $key (sort keys %{$spawn_opts})
|
foreach my $key (sort keys %{$spawn_opts})
|
||||||
{
|
{
|
||||||
print STDERR "#### ", " - $key: $spawn_opts->{$key}\n";
|
mtr_debug(" - $key: $spawn_opts->{$key}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print STDERR "#### ", " none\n";
|
mtr_debug(" none");
|
||||||
}
|
}
|
||||||
print STDERR "#### ", "-" x 78, "\n";
|
mtr_debug("-" x 73);
|
||||||
|
mtr_report("");
|
||||||
}
|
}
|
||||||
|
|
||||||
mtr_error("Can't spawn with empty \"path\"") unless defined $path;
|
mtr_error("Can't spawn with empty \"path\"") unless defined $path;
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
# same name.
|
# same name.
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
use warnings;
|
||||||
|
|
||||||
sub mtr_report_test_name($);
|
sub mtr_report_test_name($);
|
||||||
sub mtr_report_test_passed($);
|
sub mtr_report_test_passed($);
|
||||||
@ -26,7 +27,6 @@ sub mtr_report_test_failed($);
|
|||||||
sub mtr_report_test_skipped($);
|
sub mtr_report_test_skipped($);
|
||||||
sub mtr_report_test_not_skipped_though_disabled($);
|
sub mtr_report_test_not_skipped_though_disabled($);
|
||||||
|
|
||||||
sub mtr_show_failed_diff ($);
|
|
||||||
sub mtr_report_stats ($);
|
sub mtr_report_stats ($);
|
||||||
sub mtr_print_line ();
|
sub mtr_print_line ();
|
||||||
sub mtr_print_thick_line ();
|
sub mtr_print_thick_line ();
|
||||||
@ -38,6 +38,9 @@ sub mtr_child_error (@);
|
|||||||
sub mtr_debug (@);
|
sub mtr_debug (@);
|
||||||
sub mtr_verbose (@);
|
sub mtr_verbose (@);
|
||||||
|
|
||||||
|
my $tot_real_time= 0;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
@ -45,43 +48,10 @@ sub mtr_verbose (@);
|
|||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
# We can't use diff -u or diff -a as these are not portable
|
|
||||||
|
|
||||||
sub mtr_show_failed_diff ($) {
|
|
||||||
my $tinfo= shift;
|
|
||||||
|
|
||||||
# The reject and log files have been dumped to
|
|
||||||
# to filenames based on the result_file's name
|
|
||||||
my $base_file= mtr_match_extension($tinfo->{'result_file'},
|
|
||||||
"result"); # Trim extension
|
|
||||||
my $reject_file= "$base_file.reject";
|
|
||||||
my $result_file= "$base_file.result";
|
|
||||||
my $log_file= "$base_file.log";
|
|
||||||
|
|
||||||
my $diffopts= $::opt_udiff ? "-u" : "-c";
|
|
||||||
|
|
||||||
if ( -f $reject_file )
|
|
||||||
{
|
|
||||||
print "Below are the diffs between actual and expected results:\n";
|
|
||||||
print "-------------------------------------------------------\n";
|
|
||||||
# FIXME check result code?!
|
|
||||||
mtr_run("diff",[$diffopts,$result_file,$reject_file], "", "", "", "");
|
|
||||||
print "-------------------------------------------------------\n";
|
|
||||||
print "Please follow the instructions outlined at\n";
|
|
||||||
print "http://www.mysql.com/doc/en/Reporting_mysqltest_bugs.html\n";
|
|
||||||
print "to find the reason to this problem and how to report this.\n\n";
|
|
||||||
}
|
|
||||||
|
|
||||||
if ( -f $log_file )
|
|
||||||
{
|
|
||||||
print "Result from queries before failure can be found in $log_file\n";
|
|
||||||
# FIXME Maybe a tail -f -n 10 $log_file here
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
sub mtr_report_test_name ($) {
|
sub mtr_report_test_name ($) {
|
||||||
my $tinfo= shift;
|
my $tinfo= shift;
|
||||||
|
|
||||||
|
_mtr_log("$tinfo->{name}");
|
||||||
printf "%-30s ", $tinfo->{'name'};
|
printf "%-30s ", $tinfo->{'name'};
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -91,15 +61,15 @@ sub mtr_report_test_skipped ($) {
|
|||||||
$tinfo->{'result'}= 'MTR_RES_SKIPPED';
|
$tinfo->{'result'}= 'MTR_RES_SKIPPED';
|
||||||
if ( $tinfo->{'disable'} )
|
if ( $tinfo->{'disable'} )
|
||||||
{
|
{
|
||||||
print "[ disabled ] $tinfo->{'comment'}\n";
|
mtr_report("[ disabled ] $tinfo->{'comment'}");
|
||||||
}
|
}
|
||||||
elsif ( $tinfo->{'comment'} )
|
elsif ( $tinfo->{'comment'} )
|
||||||
{
|
{
|
||||||
print "[ skipped ] $tinfo->{'comment'}\n";
|
mtr_report("[ skipped ] $tinfo->{'comment'}");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print "[ skipped ]\n";
|
mtr_report("[ skipped ]");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -127,11 +97,11 @@ sub mtr_report_test_passed ($) {
|
|||||||
if ( $::opt_timer and -f "$::opt_vardir/log/timer" )
|
if ( $::opt_timer and -f "$::opt_vardir/log/timer" )
|
||||||
{
|
{
|
||||||
$timer= mtr_fromfile("$::opt_vardir/log/timer");
|
$timer= mtr_fromfile("$::opt_vardir/log/timer");
|
||||||
$::glob_tot_real_time += ($timer/1000);
|
$tot_real_time += ($timer/1000);
|
||||||
$timer= sprintf "%12s", $timer;
|
$timer= sprintf "%12s", $timer;
|
||||||
}
|
}
|
||||||
$tinfo->{'result'}= 'MTR_RES_PASSED';
|
$tinfo->{'result'}= 'MTR_RES_PASSED';
|
||||||
print "[ pass ] $timer\n";
|
mtr_report("[ pass ] $timer");
|
||||||
}
|
}
|
||||||
|
|
||||||
sub mtr_report_test_failed ($) {
|
sub mtr_report_test_failed ($) {
|
||||||
@ -140,27 +110,34 @@ sub mtr_report_test_failed ($) {
|
|||||||
$tinfo->{'result'}= 'MTR_RES_FAILED';
|
$tinfo->{'result'}= 'MTR_RES_FAILED';
|
||||||
if ( defined $tinfo->{'timeout'} )
|
if ( defined $tinfo->{'timeout'} )
|
||||||
{
|
{
|
||||||
print "[ fail ] timeout\n";
|
mtr_report("[ fail ] timeout");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print "[ fail ]\n";
|
mtr_report("[ fail ]");
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( $tinfo->{'comment'} )
|
if ( $tinfo->{'comment'} )
|
||||||
{
|
{
|
||||||
print "\nERROR: $tinfo->{'comment'}\n";
|
# The test failure has been detected by mysql-test-run.pl
|
||||||
|
# when starting the servers or due to other error, the reason for
|
||||||
|
# failing the test is saved in "comment"
|
||||||
|
mtr_report("\nERROR: $tinfo->{'comment'}");
|
||||||
}
|
}
|
||||||
elsif ( -f $::path_timefile )
|
elsif ( -f $::path_timefile )
|
||||||
{
|
{
|
||||||
print "\nErrors are (from $::path_timefile) :\n";
|
# Test failure was detected by test tool and it's report
|
||||||
|
# about what failed has been saved to file. Display the report.
|
||||||
|
print "\n";
|
||||||
print mtr_fromfile($::path_timefile); # FIXME print_file() instead
|
print mtr_fromfile($::path_timefile); # FIXME print_file() instead
|
||||||
print "\n(the last lines may be the most important ones)\n";
|
print "\n";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print "\nUnexpected termination, probably when starting mysqld\n";
|
# Neither this script or the test tool has recorded info
|
||||||
|
# about why the test has failed. Should be debugged.
|
||||||
|
mtr_report("\nUnexpected termination, probably when starting mysqld");;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -228,8 +205,10 @@ sub mtr_report_stats ($) {
|
|||||||
|
|
||||||
if ( $::opt_timer )
|
if ( $::opt_timer )
|
||||||
{
|
{
|
||||||
print
|
use English;
|
||||||
"Spent $::glob_tot_real_time seconds actually executing testcases\n"
|
|
||||||
|
mtr_report("Spent", sprintf("%.3f", $tot_real_time),"of",
|
||||||
|
time - $BASETIME, "seconds executing testcases");
|
||||||
}
|
}
|
||||||
|
|
||||||
# ----------------------------------------------------------------------
|
# ----------------------------------------------------------------------
|
||||||
@ -484,35 +463,66 @@ sub mtr_print_header () {
|
|||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Misc
|
# Log and reporting functions
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
use IO::File;
|
||||||
|
|
||||||
|
my $log_file_ref= undef;
|
||||||
|
|
||||||
|
sub mtr_log_init ($) {
|
||||||
|
my ($filename)= @_;
|
||||||
|
|
||||||
|
mtr_error("Log is already open") if defined $log_file_ref;
|
||||||
|
|
||||||
|
$log_file_ref= IO::File->new($filename, "a") or
|
||||||
|
mtr_warning("Could not create logfile $filename: $!");
|
||||||
|
}
|
||||||
|
|
||||||
|
sub _mtr_log (@) {
|
||||||
|
print $log_file_ref join(" ", @_),"\n"
|
||||||
|
if defined $log_file_ref;
|
||||||
|
}
|
||||||
|
|
||||||
sub mtr_report (@) {
|
sub mtr_report (@) {
|
||||||
|
# Print message to screen and log
|
||||||
|
_mtr_log(@_);
|
||||||
print join(" ", @_),"\n";
|
print join(" ", @_),"\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
sub mtr_warning (@) {
|
sub mtr_warning (@) {
|
||||||
|
# Print message to screen and log
|
||||||
|
_mtr_log("WARNING: ", @_);
|
||||||
print STDERR "mysql-test-run: WARNING: ",join(" ", @_),"\n";
|
print STDERR "mysql-test-run: WARNING: ",join(" ", @_),"\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
sub mtr_error (@) {
|
sub mtr_error (@) {
|
||||||
|
# Print message to screen and log
|
||||||
|
_mtr_log("ERROR: ", @_);
|
||||||
print STDERR "mysql-test-run: *** ERROR: ",join(" ", @_),"\n";
|
print STDERR "mysql-test-run: *** ERROR: ",join(" ", @_),"\n";
|
||||||
mtr_exit(1);
|
mtr_exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
sub mtr_child_error (@) {
|
sub mtr_child_error (@) {
|
||||||
|
# Print message to screen and log
|
||||||
|
_mtr_log("ERROR(child): ", @_);
|
||||||
print STDERR "mysql-test-run: *** ERROR(child): ",join(" ", @_),"\n";
|
print STDERR "mysql-test-run: *** ERROR(child): ",join(" ", @_),"\n";
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
sub mtr_debug (@) {
|
sub mtr_debug (@) {
|
||||||
|
# Only print if --script-debug is used
|
||||||
if ( $::opt_script_debug )
|
if ( $::opt_script_debug )
|
||||||
{
|
{
|
||||||
|
_mtr_log("###: ", @_);
|
||||||
print STDERR "####: ",join(" ", @_),"\n";
|
print STDERR "####: ",join(" ", @_),"\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sub mtr_verbose (@) {
|
sub mtr_verbose (@) {
|
||||||
|
# Always print to log, print to screen only when --verbose is used
|
||||||
|
_mtr_log("> ",@_);
|
||||||
if ( $::opt_verbose )
|
if ( $::opt_verbose )
|
||||||
{
|
{
|
||||||
print STDERR "> ",join(" ", @_),"\n";
|
print STDERR "> ",join(" ", @_),"\n";
|
||||||
|
@ -18,7 +18,6 @@
|
|||||||
# and is part of the translation of the Bourne shell script with the
|
# and is part of the translation of the Bourne shell script with the
|
||||||
# same name.
|
# same name.
|
||||||
|
|
||||||
use Socket;
|
|
||||||
use Errno;
|
use Errno;
|
||||||
use strict;
|
use strict;
|
||||||
|
|
||||||
@ -52,12 +51,10 @@ sub mtr_init_timers () {
|
|||||||
sub mtr_timer_start($$$) {
|
sub mtr_timer_start($$$) {
|
||||||
my ($timers,$name,$duration)= @_;
|
my ($timers,$name,$duration)= @_;
|
||||||
|
|
||||||
mtr_verbose("mtr_timer_start: $name, $duration");
|
|
||||||
|
|
||||||
if ( exists $timers->{'timers'}->{$name} )
|
if ( exists $timers->{'timers'}->{$name} )
|
||||||
{
|
{
|
||||||
# We have an old running timer, kill it
|
# We have an old running timer, kill it
|
||||||
mtr_verbose("There is an old timer running");
|
mtr_warning("There is an old timer running");
|
||||||
mtr_timer_stop($timers,$name);
|
mtr_timer_stop($timers,$name);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -75,22 +72,22 @@ sub mtr_timer_start($$$) {
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
mtr_error("can't fork");
|
mtr_error("can't fork timer, error: $!");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( $tpid )
|
if ( $tpid )
|
||||||
{
|
{
|
||||||
# Parent, record the information
|
# Parent, record the information
|
||||||
mtr_verbose("timer parent, record info($name, $tpid, $duration)");
|
mtr_verbose("Starting timer for '$name',",
|
||||||
|
"duration: $duration, pid: $tpid");
|
||||||
$timers->{'timers'}->{$name}->{'pid'}= $tpid;
|
$timers->{'timers'}->{$name}->{'pid'}= $tpid;
|
||||||
$timers->{'timers'}->{$name}->{'duration'}= $duration;
|
$timers->{'timers'}->{$name}->{'duration'}= $duration;
|
||||||
$timers->{'pids'}->{$tpid}= $name;
|
$timers->{'pids'}->{$tpid}= $name;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
# Child, redirect output and exec
|
# Child, install signal handlers and sleep for "duration"
|
||||||
# FIXME do we need to redirect streams?
|
|
||||||
|
|
||||||
# Don't do the ^C cleanup in the timeout child processes!
|
# Don't do the ^C cleanup in the timeout child processes!
|
||||||
# There is actually a race here, if we get ^C after fork(), but before
|
# There is actually a race here, if we get ^C after fork(), but before
|
||||||
@ -98,13 +95,13 @@ sub mtr_timer_start($$$) {
|
|||||||
$SIG{INT}= 'DEFAULT';
|
$SIG{INT}= 'DEFAULT';
|
||||||
|
|
||||||
$SIG{TERM}= sub {
|
$SIG{TERM}= sub {
|
||||||
mtr_verbose("timer woke up, exiting!");
|
mtr_verbose("timer $$ woke up, exiting!");
|
||||||
exit(0);
|
exit(0);
|
||||||
};
|
};
|
||||||
|
|
||||||
$0= "mtr_timer(timers,$name,$duration)";
|
$0= "mtr_timer(timers,$name,$duration)";
|
||||||
sleep($duration);
|
sleep($duration);
|
||||||
mtr_verbose("timer expired after $duration seconds");
|
mtr_verbose("timer $$ expired after $duration seconds");
|
||||||
exit(0);
|
exit(0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -114,12 +111,10 @@ sub mtr_timer_start($$$) {
|
|||||||
sub mtr_timer_stop ($$) {
|
sub mtr_timer_stop ($$) {
|
||||||
my ($timers,$name)= @_;
|
my ($timers,$name)= @_;
|
||||||
|
|
||||||
mtr_verbose("mtr_timer_stop: $name");
|
|
||||||
|
|
||||||
if ( exists $timers->{'timers'}->{$name} )
|
if ( exists $timers->{'timers'}->{$name} )
|
||||||
{
|
{
|
||||||
my $tpid= $timers->{'timers'}->{$name}->{'pid'};
|
my $tpid= $timers->{'timers'}->{$name}->{'pid'};
|
||||||
mtr_verbose("Stopping timer with pid $tpid");
|
mtr_verbose("Stopping timer for '$name' with pid $tpid");
|
||||||
|
|
||||||
# FIXME as Cygwin reuses pids fast, maybe check that is
|
# FIXME as Cygwin reuses pids fast, maybe check that is
|
||||||
# the expected process somehow?!
|
# the expected process somehow?!
|
||||||
@ -134,11 +129,8 @@ sub mtr_timer_stop ($$) {
|
|||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
mtr_error("Asked to stop timer '$name' not started");
|
||||||
mtr_error("Asked to stop timer \"$name\" not started");
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -158,7 +150,8 @@ sub mtr_timer_timeout ($$) {
|
|||||||
|
|
||||||
return "" unless exists $timers->{'pids'}->{$pid};
|
return "" unless exists $timers->{'pids'}->{$pid};
|
||||||
|
|
||||||
# We got a timeout, return the name ot the timer
|
# Got a timeout(the process with $pid is recorded as being a timer)
|
||||||
|
# return the name of the timer
|
||||||
return $timers->{'pids'}->{$pid};
|
return $timers->{'pids'}->{$pid};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -61,7 +61,6 @@ use File::Copy;
|
|||||||
use File::Temp qw /tempdir/;
|
use File::Temp qw /tempdir/;
|
||||||
use Cwd;
|
use Cwd;
|
||||||
use Getopt::Long;
|
use Getopt::Long;
|
||||||
use Sys::Hostname;
|
|
||||||
use IO::Socket;
|
use IO::Socket;
|
||||||
use IO::Socket::INET;
|
use IO::Socket::INET;
|
||||||
use strict;
|
use strict;
|
||||||
@ -83,7 +82,6 @@ require "lib/mtr_io.pl";
|
|||||||
require "lib/mtr_gcov.pl";
|
require "lib/mtr_gcov.pl";
|
||||||
require "lib/mtr_gprof.pl";
|
require "lib/mtr_gprof.pl";
|
||||||
require "lib/mtr_report.pl";
|
require "lib/mtr_report.pl";
|
||||||
require "lib/mtr_diff.pl";
|
|
||||||
require "lib/mtr_match.pl";
|
require "lib/mtr_match.pl";
|
||||||
require "lib/mtr_misc.pl";
|
require "lib/mtr_misc.pl";
|
||||||
require "lib/mtr_stress.pl";
|
require "lib/mtr_stress.pl";
|
||||||
@ -101,7 +99,6 @@ $Devel::Trace::TRACE= 1;
|
|||||||
our $mysql_version_id;
|
our $mysql_version_id;
|
||||||
our $glob_mysql_test_dir= undef;
|
our $glob_mysql_test_dir= undef;
|
||||||
our $glob_mysql_bench_dir= undef;
|
our $glob_mysql_bench_dir= undef;
|
||||||
our $glob_hostname= undef;
|
|
||||||
our $glob_scriptname= undef;
|
our $glob_scriptname= undef;
|
||||||
our $glob_timers= undef;
|
our $glob_timers= undef;
|
||||||
our $glob_use_embedded_server= 0;
|
our $glob_use_embedded_server= 0;
|
||||||
@ -234,7 +231,6 @@ my $opt_report_features;
|
|||||||
our $opt_check_testcases;
|
our $opt_check_testcases;
|
||||||
our $opt_mark_progress;
|
our $opt_mark_progress;
|
||||||
|
|
||||||
our $opt_skip;
|
|
||||||
our $opt_skip_rpl;
|
our $opt_skip_rpl;
|
||||||
our $max_slave_num= 0;
|
our $max_slave_num= 0;
|
||||||
our $max_master_num= 1;
|
our $max_master_num= 1;
|
||||||
@ -277,13 +273,8 @@ our $opt_stress_test_duration= 0;
|
|||||||
our $opt_stress_init_file= "";
|
our $opt_stress_init_file= "";
|
||||||
our $opt_stress_test_file= "";
|
our $opt_stress_test_file= "";
|
||||||
|
|
||||||
our $opt_wait_for_master;
|
|
||||||
our $opt_wait_for_slave;
|
|
||||||
|
|
||||||
our $opt_warnings;
|
our $opt_warnings;
|
||||||
|
|
||||||
our $opt_udiff;
|
|
||||||
|
|
||||||
our $opt_skip_ndbcluster= 0;
|
our $opt_skip_ndbcluster= 0;
|
||||||
our $opt_skip_ndbcluster_slave= 0;
|
our $opt_skip_ndbcluster_slave= 0;
|
||||||
our $opt_with_ndbcluster= 0;
|
our $opt_with_ndbcluster= 0;
|
||||||
@ -307,7 +298,6 @@ our @data_dir_lst;
|
|||||||
our $used_binlog_format;
|
our $used_binlog_format;
|
||||||
our $used_default_engine;
|
our $used_default_engine;
|
||||||
our $debug_compiled_binaries;
|
our $debug_compiled_binaries;
|
||||||
our $glob_tot_real_time= 0;
|
|
||||||
|
|
||||||
our %mysqld_variables;
|
our %mysqld_variables;
|
||||||
|
|
||||||
@ -619,7 +609,6 @@ sub command_line_setup () {
|
|||||||
'start-dirty' => \$opt_start_dirty,
|
'start-dirty' => \$opt_start_dirty,
|
||||||
'start-and-exit' => \$opt_start_and_exit,
|
'start-and-exit' => \$opt_start_and_exit,
|
||||||
'timer!' => \$opt_timer,
|
'timer!' => \$opt_timer,
|
||||||
'unified-diff|udiff' => \$opt_udiff,
|
|
||||||
'user=s' => \$opt_user,
|
'user=s' => \$opt_user,
|
||||||
'testcase-timeout=i' => \$opt_testcase_timeout,
|
'testcase-timeout=i' => \$opt_testcase_timeout,
|
||||||
'suite-timeout=i' => \$opt_suite_timeout,
|
'suite-timeout=i' => \$opt_suite_timeout,
|
||||||
@ -655,8 +644,6 @@ sub command_line_setup () {
|
|||||||
$source_dist= 1;
|
$source_dist= 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
$glob_hostname= mtr_short_hostname();
|
|
||||||
|
|
||||||
# Find the absolute path to the test directory
|
# Find the absolute path to the test directory
|
||||||
$glob_mysql_test_dir= cwd();
|
$glob_mysql_test_dir= cwd();
|
||||||
if ( $glob_cygwin_perl )
|
if ( $glob_cygwin_perl )
|
||||||
@ -2209,7 +2196,7 @@ sub remove_stale_vardir () {
|
|||||||
{
|
{
|
||||||
# Remove the directory which the link points at
|
# Remove the directory which the link points at
|
||||||
mtr_verbose("Removing " . readlink($opt_vardir));
|
mtr_verbose("Removing " . readlink($opt_vardir));
|
||||||
rmtree(readlink($opt_vardir));
|
mtr_rmtree(readlink($opt_vardir));
|
||||||
|
|
||||||
# Remove the "var" symlink
|
# Remove the "var" symlink
|
||||||
mtr_verbose("unlink($opt_vardir)");
|
mtr_verbose("unlink($opt_vardir)");
|
||||||
@ -2237,7 +2224,7 @@ sub remove_stale_vardir () {
|
|||||||
foreach my $bin ( glob("$opt_vardir/*") )
|
foreach my $bin ( glob("$opt_vardir/*") )
|
||||||
{
|
{
|
||||||
mtr_verbose("Removing bin $bin");
|
mtr_verbose("Removing bin $bin");
|
||||||
rmtree($bin);
|
mtr_rmtree($bin);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2245,7 +2232,7 @@ sub remove_stale_vardir () {
|
|||||||
{
|
{
|
||||||
# Remove the entire "var" dir
|
# Remove the entire "var" dir
|
||||||
mtr_verbose("Removing $opt_vardir/");
|
mtr_verbose("Removing $opt_vardir/");
|
||||||
rmtree("$opt_vardir/");
|
mtr_rmtree("$opt_vardir/");
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( $opt_mem )
|
if ( $opt_mem )
|
||||||
@ -2254,7 +2241,7 @@ sub remove_stale_vardir () {
|
|||||||
# remove the $opt_mem dir to assure the symlink
|
# remove the $opt_mem dir to assure the symlink
|
||||||
# won't point at an old directory
|
# won't point at an old directory
|
||||||
mtr_verbose("Removing $opt_mem");
|
mtr_verbose("Removing $opt_mem");
|
||||||
rmtree($opt_mem);
|
mtr_rmtree($opt_mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -2267,11 +2254,11 @@ sub remove_stale_vardir () {
|
|||||||
# Remove the var/ dir in mysql-test dir if any
|
# Remove the var/ dir in mysql-test dir if any
|
||||||
# this could be an old symlink that shouldn't be there
|
# this could be an old symlink that shouldn't be there
|
||||||
mtr_verbose("Removing $default_vardir");
|
mtr_verbose("Removing $default_vardir");
|
||||||
rmtree($default_vardir);
|
mtr_rmtree($default_vardir);
|
||||||
|
|
||||||
# Remove the "var" dir
|
# Remove the "var" dir
|
||||||
mtr_verbose("Removing $opt_vardir/");
|
mtr_verbose("Removing $opt_vardir/");
|
||||||
rmtree("$opt_vardir/");
|
mtr_rmtree("$opt_vardir/");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2924,13 +2911,16 @@ sub initialize_servers () {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
check_running_as_root();
|
check_running_as_root();
|
||||||
|
|
||||||
|
mtr_log_init("$opt_vardir/log/mysql-test-run.log");
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
sub mysql_install_db () {
|
sub mysql_install_db () {
|
||||||
|
|
||||||
install_db('master', $master->[0]->{'path_myddir'});
|
install_db('master', $master->[0]->{'path_myddir'});
|
||||||
|
|
||||||
if ($max_master_num)
|
if ($max_master_num > 1)
|
||||||
{
|
{
|
||||||
copy_install_db('master', $master->[1]->{'path_myddir'});
|
copy_install_db('master', $master->[1]->{'path_myddir'});
|
||||||
}
|
}
|
||||||
@ -3092,11 +3082,15 @@ sub install_db ($$) {
|
|||||||
mtr_appendfile_to_file("$path_sql_dir/fill_help_tables.sql",
|
mtr_appendfile_to_file("$path_sql_dir/fill_help_tables.sql",
|
||||||
$bootstrap_sql_file);
|
$bootstrap_sql_file);
|
||||||
|
|
||||||
|
mtr_tofile($bootstrap_sql_file,
|
||||||
|
"DELETE FROM mysql.user where user= '';");
|
||||||
|
|
||||||
# Log bootstrap command
|
# Log bootstrap command
|
||||||
my $path_bootstrap_log= "$opt_vardir/log/bootstrap.log";
|
my $path_bootstrap_log= "$opt_vardir/log/bootstrap.log";
|
||||||
mtr_tofile($path_bootstrap_log,
|
mtr_tofile($path_bootstrap_log,
|
||||||
"$exe_mysqld_bootstrap " . join(" ", @$args) . "\n");
|
"$exe_mysqld_bootstrap " . join(" ", @$args) . "\n");
|
||||||
|
|
||||||
|
|
||||||
if ( mtr_run($exe_mysqld_bootstrap, $args, $bootstrap_sql_file,
|
if ( mtr_run($exe_mysqld_bootstrap, $args, $bootstrap_sql_file,
|
||||||
$path_bootstrap_log, $path_bootstrap_log,
|
$path_bootstrap_log, $path_bootstrap_log,
|
||||||
"", { append_log_file => 1 }) != 0 )
|
"", { append_log_file => 1 }) != 0 )
|
||||||
@ -3221,7 +3215,7 @@ sub restore_slave_databases ($) {
|
|||||||
{
|
{
|
||||||
my $data_dir= $slave->[$idx]->{'path_myddir'};
|
my $data_dir= $slave->[$idx]->{'path_myddir'};
|
||||||
my $name= basename($data_dir);
|
my $name= basename($data_dir);
|
||||||
rmtree($data_dir);
|
mtr_rmtree($data_dir);
|
||||||
mtr_copy_dir("$path_snapshot/$name", $data_dir);
|
mtr_copy_dir("$path_snapshot/$name", $data_dir);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3394,56 +3388,6 @@ sub find_testcase_skipped_reason($)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
sub analyze_testcase_failure_sync_with_master($)
|
|
||||||
{
|
|
||||||
my ($tinfo)= @_;
|
|
||||||
|
|
||||||
my $args;
|
|
||||||
mtr_init_args(\$args);
|
|
||||||
|
|
||||||
mtr_add_arg($args, "--no-defaults");
|
|
||||||
mtr_add_arg($args, "--silent");
|
|
||||||
mtr_add_arg($args, "--skip-safemalloc");
|
|
||||||
mtr_add_arg($args, "--tmpdir=%s", $opt_tmpdir);
|
|
||||||
mtr_add_arg($args, "--character-sets-dir=%s", $path_charsetsdir);
|
|
||||||
|
|
||||||
mtr_add_arg($args, "--socket=%s", $master->[0]->{'path_sock'});
|
|
||||||
mtr_add_arg($args, "--port=%d", $master->[0]->{'port'});
|
|
||||||
mtr_add_arg($args, "--database=test");
|
|
||||||
mtr_add_arg($args, "--user=%s", $opt_user);
|
|
||||||
mtr_add_arg($args, "--password=");
|
|
||||||
|
|
||||||
# Run the test file and append output to log file
|
|
||||||
mtr_run_test($exe_mysqltest,$args,
|
|
||||||
"include/analyze_failure_sync_with_master.test",
|
|
||||||
"$path_timefile", "$path_timefile","",
|
|
||||||
{ append_log_file => 1 });
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
sub analyze_testcase_failure($)
|
|
||||||
{
|
|
||||||
my ($tinfo)= @_;
|
|
||||||
|
|
||||||
# Open mysqltest.log
|
|
||||||
my $F= IO::File->new($path_timefile)
|
|
||||||
or return;
|
|
||||||
|
|
||||||
while ( my $line= <$F> )
|
|
||||||
{
|
|
||||||
# Look for "mysqltest: At line nnn: <error>
|
|
||||||
if ( $line =~ /mysqltest: At line [0-9]*: (.*)/ )
|
|
||||||
{
|
|
||||||
my $error= $1;
|
|
||||||
# Look for "could not sync with master"
|
|
||||||
if ( $error =~ /could not sync with master/ )
|
|
||||||
{
|
|
||||||
analyze_testcase_failure_sync_with_master($tinfo);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Run a single test case
|
# Run a single test case
|
||||||
@ -3543,10 +3487,6 @@ sub run_testcase ($) {
|
|||||||
}
|
}
|
||||||
elsif ( $res == 1 )
|
elsif ( $res == 1 )
|
||||||
{
|
{
|
||||||
if ( $opt_force )
|
|
||||||
{
|
|
||||||
analyze_testcase_failure($tinfo);
|
|
||||||
}
|
|
||||||
# Test case failure reported by mysqltest
|
# Test case failure reported by mysqltest
|
||||||
report_failure_and_restart($tinfo);
|
report_failure_and_restart($tinfo);
|
||||||
}
|
}
|
||||||
@ -3580,7 +3520,7 @@ sub run_testcase ($) {
|
|||||||
sub save_installed_db () {
|
sub save_installed_db () {
|
||||||
|
|
||||||
mtr_report("Saving snapshot of installed databases");
|
mtr_report("Saving snapshot of installed databases");
|
||||||
rmtree($path_snapshot);
|
mtr_rmtree($path_snapshot);
|
||||||
|
|
||||||
foreach my $data_dir (@data_dir_lst)
|
foreach my $data_dir (@data_dir_lst)
|
||||||
{
|
{
|
||||||
@ -3627,7 +3567,7 @@ sub restore_installed_db ($) {
|
|||||||
{
|
{
|
||||||
my $name= basename($data_dir);
|
my $name= basename($data_dir);
|
||||||
save_files_before_restore($test_name, $data_dir);
|
save_files_before_restore($test_name, $data_dir);
|
||||||
rmtree("$data_dir");
|
mtr_rmtree("$data_dir");
|
||||||
mtr_copy_dir("$path_snapshot/$name", "$data_dir");
|
mtr_copy_dir("$path_snapshot/$name", "$data_dir");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3637,7 +3577,7 @@ sub restore_installed_db ($) {
|
|||||||
{
|
{
|
||||||
foreach my $ndbd (@{$cluster->{'ndbds'}})
|
foreach my $ndbd (@{$cluster->{'ndbds'}})
|
||||||
{
|
{
|
||||||
rmtree("$ndbd->{'path_fs'}" );
|
mtr_rmtree("$ndbd->{'path_fs'}" );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3652,7 +3592,6 @@ sub report_failure_and_restart ($) {
|
|||||||
my $tinfo= shift;
|
my $tinfo= shift;
|
||||||
|
|
||||||
mtr_report_test_failed($tinfo);
|
mtr_report_test_failed($tinfo);
|
||||||
mtr_show_failed_diff($tinfo);
|
|
||||||
print "\n";
|
print "\n";
|
||||||
if ( $opt_force )
|
if ( $opt_force )
|
||||||
{
|
{
|
||||||
@ -3661,13 +3600,13 @@ sub report_failure_and_restart ($) {
|
|||||||
|
|
||||||
# Restore the snapshot of the installed test db
|
# Restore the snapshot of the installed test db
|
||||||
restore_installed_db($tinfo->{'name'});
|
restore_installed_db($tinfo->{'name'});
|
||||||
print "Resuming Tests\n\n";
|
mtr_report("Resuming Tests\n");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
my $test_mode= join(" ", @::glob_test_mode) || "default";
|
my $test_mode= join(" ", @::glob_test_mode) || "default";
|
||||||
print "Aborting: $tinfo->{'name'} failed in $test_mode mode. ";
|
mtr_report("Aborting: $tinfo->{'name'} failed in $test_mode mode. ");
|
||||||
print "To continue, re-run with '--force'.\n";
|
mtr_report("To continue, re-run with '--force'.");
|
||||||
if ( ! $glob_debugger and
|
if ( ! $glob_debugger and
|
||||||
! $opt_extern and
|
! $opt_extern and
|
||||||
! $glob_use_embedded_server )
|
! $glob_use_embedded_server )
|
||||||
@ -4093,6 +4032,9 @@ sub mysqld_start ($$$) {
|
|||||||
$wait_for_pid_file= 0;
|
$wait_for_pid_file= 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Remove the pidfile
|
||||||
|
unlink($mysqld->{'path_pid'});
|
||||||
|
|
||||||
if ( defined $exe )
|
if ( defined $exe )
|
||||||
{
|
{
|
||||||
$pid= mtr_spawn($exe, $args, "",
|
$pid= mtr_spawn($exe, $args, "",
|
||||||
@ -4126,11 +4068,11 @@ sub mysqld_start ($$$) {
|
|||||||
|
|
||||||
sub stop_all_servers () {
|
sub stop_all_servers () {
|
||||||
|
|
||||||
print "Stopping All Servers\n";
|
mtr_report("Stopping All Servers");
|
||||||
|
|
||||||
if ( ! $opt_skip_im )
|
if ( ! $opt_skip_im )
|
||||||
{
|
{
|
||||||
print "Shutting-down Instance Manager\n";
|
mtr_report("Shutting-down Instance Manager");
|
||||||
unless (mtr_im_stop($instance_manager, "stop_all_servers"))
|
unless (mtr_im_stop($instance_manager, "stop_all_servers"))
|
||||||
{
|
{
|
||||||
mtr_error("Failed to stop Instance Manager.")
|
mtr_error("Failed to stop Instance Manager.")
|
||||||
@ -4840,6 +4782,9 @@ sub run_mysqltest ($) {
|
|||||||
|
|
||||||
mtr_add_arg($args, "--test-file=%s", $tinfo->{'path'});
|
mtr_add_arg($args, "--test-file=%s", $tinfo->{'path'});
|
||||||
|
|
||||||
|
# Number of lines of resut to include in failure report
|
||||||
|
mtr_add_arg($args, "--tail-lines=20");
|
||||||
|
|
||||||
if ( defined $tinfo->{'result_file'} ) {
|
if ( defined $tinfo->{'result_file'} ) {
|
||||||
mtr_add_arg($args, "--result-file=%s", $tinfo->{'result_file'});
|
mtr_add_arg($args, "--result-file=%s", $tinfo->{'result_file'});
|
||||||
}
|
}
|
||||||
@ -5253,7 +5198,6 @@ Misc options
|
|||||||
fast Don't try to clean up from earlier runs
|
fast Don't try to clean up from earlier runs
|
||||||
reorder Reorder tests to get fewer server restarts
|
reorder Reorder tests to get fewer server restarts
|
||||||
help Get this help text
|
help Get this help text
|
||||||
unified-diff | udiff When presenting differences, use unified diff
|
|
||||||
|
|
||||||
testcase-timeout=MINUTES Max test case run time (default $default_testcase_timeout)
|
testcase-timeout=MINUTES Max test case run time (default $default_testcase_timeout)
|
||||||
suite-timeout=MINUTES Max test suite run time (default $default_suite_timeout)
|
suite-timeout=MINUTES Max test suite run time (default $default_suite_timeout)
|
||||||
|
@ -80,7 +80,7 @@ select STR_TO_DATE('2004.12.12 22.30.61','%Y.%m.%d %T');
|
|||||||
STR_TO_DATE('2004.12.12 22.30.61','%Y.%m.%d %T')
|
STR_TO_DATE('2004.12.12 22.30.61','%Y.%m.%d %T')
|
||||||
NULL
|
NULL
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect time value: '22.30.61' for function str_to_time
|
Error 1411 Incorrect time value: '22.30.61' for function str_to_date
|
||||||
create table t1 (date char(30), format char(30) not null);
|
create table t1 (date char(30), format char(30) not null);
|
||||||
insert into t1 values
|
insert into t1 values
|
||||||
('2003-01-02 10:11:12', '%Y-%m-%d %H:%i:%S'),
|
('2003-01-02 10:11:12', '%Y-%m-%d %H:%i:%S'),
|
||||||
@ -352,21 +352,21 @@ Tuesday 52 2001 %W %u %x NULL
|
|||||||
7 53 1998 %w %u %Y NULL
|
7 53 1998 %w %u %Y NULL
|
||||||
NULL %m.%d.%Y NULL
|
NULL %m.%d.%Y NULL
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12.123456' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12.123456' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AM' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AN' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AN' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '10:20:10AM' for function str_to_time
|
Error 1411 Incorrect datetime value: '10:20:10AM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '15 Septembei 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: '15 Septembei 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '15 Ju 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: '15 Ju 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Sund 15 MA' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Sund 15 MA' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Thursdai 12 1998' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Thursdai 12 1998' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Sunday 01 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Sunday 01 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '7 53 1998' for function str_to_time
|
Error 1411 Incorrect datetime value: '7 53 1998' for function str_to_date
|
||||||
select date,format,concat(str_to_date(date, format),'') as con from t1;
|
select date,format,concat(str_to_date(date, format),'') as con from t1;
|
||||||
date format con
|
date format con
|
||||||
2003-01-02 10:11:12 PM %Y-%m-%d %H:%i:%S %p NULL
|
2003-01-02 10:11:12 PM %Y-%m-%d %H:%i:%S %p NULL
|
||||||
@ -386,21 +386,21 @@ Tuesday 52 2001 %W %u %x NULL
|
|||||||
7 53 1998 %w %u %Y NULL
|
7 53 1998 %w %u %Y NULL
|
||||||
NULL %m.%d.%Y NULL
|
NULL %m.%d.%Y NULL
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12.123456' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12.123456' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AM' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AN' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12AN' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_time
|
Error 1411 Incorrect datetime value: '2003-01-02 10:11:12 PM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '10:20:10AM' for function str_to_time
|
Error 1411 Incorrect datetime value: '10:20:10AM' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '15 Septembei 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: '15 Septembei 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '15 Ju 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: '15 Ju 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Sund 15 MA' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Sund 15 MA' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Thursdai 12 1998' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Thursdai 12 1998' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Sunday 01 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Sunday 01 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_time
|
Error 1411 Incorrect datetime value: 'Tuesday 52 2001' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '7 53 1998' for function str_to_time
|
Error 1411 Incorrect datetime value: '7 53 1998' for function str_to_date
|
||||||
truncate table t1;
|
truncate table t1;
|
||||||
insert into t1 values
|
insert into t1 values
|
||||||
('10:20:10AM', '%h:%i:%s'),
|
('10:20:10AM', '%h:%i:%s'),
|
||||||
@ -440,7 +440,7 @@ select str_to_date('15-01-2001 12:59:59', GET_FORMAT(DATE,'USA'));
|
|||||||
str_to_date('15-01-2001 12:59:59', GET_FORMAT(DATE,'USA'))
|
str_to_date('15-01-2001 12:59:59', GET_FORMAT(DATE,'USA'))
|
||||||
NULL
|
NULL
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect datetime value: '15-01-2001 12:59:59' for function str_to_time
|
Error 1411 Incorrect datetime value: '15-01-2001 12:59:59' for function str_to_date
|
||||||
explain extended select makedate(1997,1), addtime("31.12.97 11.59.59.999999 PM", "1 1.1.1.000002"),subtime("31.12.97 11.59.59.999999 PM", "1 1.1.1.000002"),timediff("01.01.97 11:59:59.000001 PM","31.12.95 11:59:59.000002 PM"),cast(str_to_date("15-01-2001 12:59:59", "%d-%m-%Y %H:%i:%S") as TIME), maketime(23,11,12),microsecond("1997-12-31 23:59:59.000001");
|
explain extended select makedate(1997,1), addtime("31.12.97 11.59.59.999999 PM", "1 1.1.1.000002"),subtime("31.12.97 11.59.59.999999 PM", "1 1.1.1.000002"),timediff("01.01.97 11:59:59.000001 PM","31.12.95 11:59:59.000002 PM"),cast(str_to_date("15-01-2001 12:59:59", "%d-%m-%Y %H:%i:%S") as TIME), maketime(23,11,12),microsecond("1997-12-31 23:59:59.000001");
|
||||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||||
|
@ -191,3 +191,7 @@ drop table table_26093;
|
|||||||
drop function func_26093_a;
|
drop function func_26093_a;
|
||||||
drop function func_26093_b;
|
drop function func_26093_b;
|
||||||
End of 5.0 tests
|
End of 5.0 tests
|
||||||
|
select connection_id() > 0;
|
||||||
|
connection_id() > 0
|
||||||
|
1
|
||||||
|
End of tests
|
||||||
|
@ -501,7 +501,7 @@ ERROR 23000: Duplicate entry 'test2' for key 'ggid'
|
|||||||
select * from t1;
|
select * from t1;
|
||||||
id ggid email passwd
|
id ggid email passwd
|
||||||
1 this will work
|
1 this will work
|
||||||
3 test2 this will work
|
4 test2 this will work
|
||||||
select * from t1 where id=1;
|
select * from t1 where id=1;
|
||||||
id ggid email passwd
|
id ggid email passwd
|
||||||
1 this will work
|
1 this will work
|
||||||
|
@ -3,7 +3,9 @@ mysql.columns_priv OK
|
|||||||
mysql.db OK
|
mysql.db OK
|
||||||
mysql.event OK
|
mysql.event OK
|
||||||
mysql.func OK
|
mysql.func OK
|
||||||
mysql.general_log OK
|
mysql.general_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.help_category OK
|
mysql.help_category OK
|
||||||
mysql.help_keyword OK
|
mysql.help_keyword OK
|
||||||
mysql.help_relation OK
|
mysql.help_relation OK
|
||||||
@ -14,7 +16,9 @@ mysql.plugin OK
|
|||||||
mysql.proc OK
|
mysql.proc OK
|
||||||
mysql.procs_priv OK
|
mysql.procs_priv OK
|
||||||
mysql.servers OK
|
mysql.servers OK
|
||||||
mysql.slow_log OK
|
mysql.slow_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.tables_priv OK
|
mysql.tables_priv OK
|
||||||
mysql.time_zone OK
|
mysql.time_zone OK
|
||||||
mysql.time_zone_leap_second OK
|
mysql.time_zone_leap_second OK
|
||||||
@ -29,7 +33,9 @@ mysql.columns_priv OK
|
|||||||
mysql.db OK
|
mysql.db OK
|
||||||
mysql.event OK
|
mysql.event OK
|
||||||
mysql.func OK
|
mysql.func OK
|
||||||
mysql.general_log OK
|
mysql.general_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.help_category OK
|
mysql.help_category OK
|
||||||
mysql.help_keyword OK
|
mysql.help_keyword OK
|
||||||
mysql.help_relation OK
|
mysql.help_relation OK
|
||||||
@ -40,7 +46,9 @@ mysql.plugin OK
|
|||||||
mysql.proc OK
|
mysql.proc OK
|
||||||
mysql.procs_priv OK
|
mysql.procs_priv OK
|
||||||
mysql.servers OK
|
mysql.servers OK
|
||||||
mysql.slow_log OK
|
mysql.slow_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.tables_priv OK
|
mysql.tables_priv OK
|
||||||
mysql.time_zone OK
|
mysql.time_zone OK
|
||||||
mysql.time_zone_leap_second OK
|
mysql.time_zone_leap_second OK
|
||||||
@ -55,7 +63,9 @@ mysql.columns_priv OK
|
|||||||
mysql.db OK
|
mysql.db OK
|
||||||
mysql.event OK
|
mysql.event OK
|
||||||
mysql.func OK
|
mysql.func OK
|
||||||
mysql.general_log OK
|
mysql.general_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.help_category OK
|
mysql.help_category OK
|
||||||
mysql.help_keyword OK
|
mysql.help_keyword OK
|
||||||
mysql.help_relation OK
|
mysql.help_relation OK
|
||||||
@ -66,7 +76,9 @@ mysql.plugin OK
|
|||||||
mysql.proc OK
|
mysql.proc OK
|
||||||
mysql.procs_priv OK
|
mysql.procs_priv OK
|
||||||
mysql.servers OK
|
mysql.servers OK
|
||||||
mysql.slow_log OK
|
mysql.slow_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.tables_priv OK
|
mysql.tables_priv OK
|
||||||
mysql.time_zone OK
|
mysql.time_zone OK
|
||||||
mysql.time_zone_leap_second OK
|
mysql.time_zone_leap_second OK
|
||||||
@ -83,7 +95,9 @@ mysql.columns_priv OK
|
|||||||
mysql.db OK
|
mysql.db OK
|
||||||
mysql.event OK
|
mysql.event OK
|
||||||
mysql.func OK
|
mysql.func OK
|
||||||
mysql.general_log OK
|
mysql.general_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.help_category OK
|
mysql.help_category OK
|
||||||
mysql.help_keyword OK
|
mysql.help_keyword OK
|
||||||
mysql.help_relation OK
|
mysql.help_relation OK
|
||||||
@ -94,7 +108,9 @@ mysql.plugin OK
|
|||||||
mysql.proc OK
|
mysql.proc OK
|
||||||
mysql.procs_priv OK
|
mysql.procs_priv OK
|
||||||
mysql.servers OK
|
mysql.servers OK
|
||||||
mysql.slow_log OK
|
mysql.slow_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
mysql.tables_priv OK
|
mysql.tables_priv OK
|
||||||
mysql.time_zone OK
|
mysql.time_zone OK
|
||||||
mysql.time_zone_leap_second OK
|
mysql.time_zone_leap_second OK
|
||||||
|
@ -280,8 +280,20 @@ let $B = changed value of B;
|
|||||||
var2: content of variable 1
|
var2: content of variable 1
|
||||||
var3: content of variable 1 content of variable 1
|
var3: content of variable 1 content of variable 1
|
||||||
length of var3 is longer than 0
|
length of var3 is longer than 0
|
||||||
|
var1
|
||||||
|
hi 1 hi there
|
||||||
|
var2
|
||||||
|
2
|
||||||
|
var2 again
|
||||||
|
2
|
||||||
|
var3 two columns with same name
|
||||||
|
1 2 3
|
||||||
|
var4 from query that returns NULL
|
||||||
|
var5 from query that returns no row
|
||||||
|
failing query in let
|
||||||
|
mysqltest: At line 1: Error running query 'failing query': 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'failing query' at line 1
|
||||||
mysqltest: At line 1: Missing required argument 'filename' to command 'source'
|
mysqltest: At line 1: Missing required argument 'filename' to command 'source'
|
||||||
mysqltest: At line 1: Could not open file ./non_existingFile
|
mysqltest: At line 1: Could not open file './non_existingFile'
|
||||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/recursive.sql": At line 1: Source directives are nesting too deep
|
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/recursive.sql": At line 1: Source directives are nesting too deep
|
||||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/error.sql": At line 1: query 'garbage ' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'garbage' at line 1
|
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/error.sql": At line 1: query 'garbage ' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'garbage' at line 1
|
||||||
|
|
||||||
@ -340,6 +352,8 @@ here is the sourced script
|
|||||||
In loop
|
In loop
|
||||||
here is the sourced script
|
here is the sourced script
|
||||||
here is the sourced script
|
here is the sourced script
|
||||||
|
"hello"
|
||||||
|
"hello"
|
||||||
mysqltest: At line 1: Missing argument to sleep
|
mysqltest: At line 1: Missing argument to sleep
|
||||||
mysqltest: At line 1: Missing argument to real_sleep
|
mysqltest: At line 1: Missing argument to real_sleep
|
||||||
mysqltest: At line 1: Invalid argument to sleep "abc"
|
mysqltest: At line 1: Invalid argument to sleep "abc"
|
||||||
@ -461,7 +475,6 @@ root@localhost
|
|||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
this will be executed
|
this will be executed
|
||||||
this will be executed
|
this will be executed
|
||||||
mysqltest: Result length mismatch
|
|
||||||
mysqltest: The test didn't produce any output
|
mysqltest: The test didn't produce any output
|
||||||
Failing multi statement query
|
Failing multi statement query
|
||||||
mysqltest: At line 3: query 'create table t1 (a int primary key);
|
mysqltest: At line 3: query 'create table t1 (a int primary key);
|
||||||
@ -473,6 +486,8 @@ mysqltest: At line 3: query 'create table t1 (a int primary key);
|
|||||||
insert into t1 values (1);
|
insert into t1 values (1);
|
||||||
select 'select-me';
|
select 'select-me';
|
||||||
insertz 'error query'' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'insertz 'error query'' at line 1
|
insertz 'error query'' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'insertz 'error query'' at line 1
|
||||||
|
|
||||||
|
More results from queries before failure can be found in MYSQLTEST_VARDIR/log/bug11731.log
|
||||||
drop table t1;
|
drop table t1;
|
||||||
Multi statement using expected error
|
Multi statement using expected error
|
||||||
create table t1 (a int primary key);
|
create table t1 (a int primary key);
|
||||||
@ -520,17 +535,19 @@ drop table t1;
|
|||||||
mysqltest: At line 1: Missing required argument 'filename' to command 'remove_file'
|
mysqltest: At line 1: Missing required argument 'filename' to command 'remove_file'
|
||||||
mysqltest: At line 1: Missing required argument 'filename' to command 'write_file'
|
mysqltest: At line 1: Missing required argument 'filename' to command 'write_file'
|
||||||
mysqltest: At line 1: End of file encountered before 'EOF' delimiter was found
|
mysqltest: At line 1: End of file encountered before 'EOF' delimiter was found
|
||||||
|
Content for test_file1
|
||||||
|
mysqltest: At line 1: File already exist: 'MYSQLTEST_VARDIR/tmp/test_file1.tmp'
|
||||||
Some data
|
Some data
|
||||||
for cat_file command
|
for cat_file command
|
||||||
of mysqltest
|
of mysqltest
|
||||||
mysqltest: At line 1: Failed to open file non_existing_file
|
mysqltest: At line 1: Failed to open file 'non_existing_file'
|
||||||
mysqltest: At line 1: Missing required argument 'filename' to command 'file_exists'
|
mysqltest: At line 1: Missing required argument 'filename' to command 'file_exists'
|
||||||
mysqltest: At line 1: Missing required argument 'from_file' to command 'copy_file'
|
mysqltest: At line 1: Missing required argument 'from_file' to command 'copy_file'
|
||||||
mysqltest: At line 1: Missing required argument 'to_file' to command 'copy_file'
|
mysqltest: At line 1: Missing required argument 'to_file' to command 'copy_file'
|
||||||
mysqltest: At line 1: Missing required argument 'mode' to command 'chmod'
|
mysqltest: At line 1: Missing required argument 'mode' to command 'chmod'
|
||||||
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
||||||
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
||||||
mysqltest: At line 1: Missing required argument 'file' to command 'chmod'
|
mysqltest: At line 1: Missing required argument 'filename' to command 'chmod'
|
||||||
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
||||||
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
mysqltest: At line 1: You must write a 4 digit octal number for mode
|
||||||
hello
|
hello
|
||||||
|
@ -215,11 +215,11 @@ ERROR 22007: Incorrect date value: '2004-10-00 15:30:00' for column 'col1' at ro
|
|||||||
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('31.9.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('31.9.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR 22007: Incorrect date value: '2004-09-31 15:30:00' for column 'col1' at row 1
|
ERROR 22007: Incorrect date value: '2004-09-31 15:30:00' for column 'col1' at row 1
|
||||||
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_time
|
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_date
|
||||||
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('29.02.2003 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('29.02.2003 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR 22007: Incorrect date value: '2003-02-29 15:30:00' for column 'col1' at row 1
|
ERROR 22007: Incorrect date value: '2003-02-29 15:30:00' for column 'col1' at row 1
|
||||||
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('15.13.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('15.13.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR HY000: Incorrect datetime value: '15.13.2004 15.30' for function str_to_time
|
ERROR HY000: Incorrect datetime value: '15.13.2004 15.30' for function str_to_date
|
||||||
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('00.00.0000','%d.%m.%Y'));
|
INSERT INTO t1 (col1) VALUES(STR_TO_DATE('00.00.0000','%d.%m.%Y'));
|
||||||
ERROR 22007: Incorrect date value: '0000-00-00' for column 'col1' at row 1
|
ERROR 22007: Incorrect date value: '0000-00-00' for column 'col1' at row 1
|
||||||
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('31.10.0000 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('31.10.0000 15.30','%d.%m.%Y %H.%i'));
|
||||||
@ -230,11 +230,11 @@ ERROR 22007: Incorrect datetime value: '2004-10-00 15:30:00' for column 'col2' a
|
|||||||
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('31.9.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('31.9.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR 22007: Incorrect datetime value: '2004-09-31 15:30:00' for column 'col2' at row 1
|
ERROR 22007: Incorrect datetime value: '2004-09-31 15:30:00' for column 'col2' at row 1
|
||||||
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_time
|
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_date
|
||||||
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('29.02.2003 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('29.02.2003 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR 22007: Incorrect datetime value: '2003-02-29 15:30:00' for column 'col2' at row 1
|
ERROR 22007: Incorrect datetime value: '2003-02-29 15:30:00' for column 'col2' at row 1
|
||||||
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('15.13.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('15.13.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR HY000: Incorrect datetime value: '15.13.2004 15.30' for function str_to_time
|
ERROR HY000: Incorrect datetime value: '15.13.2004 15.30' for function str_to_date
|
||||||
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('00.00.0000','%d.%m.%Y'));
|
INSERT INTO t1 (col2) VALUES(STR_TO_DATE('00.00.0000','%d.%m.%Y'));
|
||||||
ERROR 22007: Incorrect datetime value: '0000-00-00' for column 'col2' at row 1
|
ERROR 22007: Incorrect datetime value: '0000-00-00' for column 'col2' at row 1
|
||||||
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('31.10.0000 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('31.10.0000 15.30','%d.%m.%Y %H.%i'));
|
||||||
@ -246,11 +246,11 @@ ERROR 22007: Incorrect datetime value: '2004-10-00 15:30:00' for column 'col3' a
|
|||||||
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('31.9.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('31.9.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR 22007: Incorrect datetime value: '2004-09-31 15:30:00' for column 'col3' at row 1
|
ERROR 22007: Incorrect datetime value: '2004-09-31 15:30:00' for column 'col3' at row 1
|
||||||
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_time
|
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_date
|
||||||
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('29.02.2003 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('29.02.2003 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR 22007: Incorrect datetime value: '2003-02-29 15:30:00' for column 'col3' at row 1
|
ERROR 22007: Incorrect datetime value: '2003-02-29 15:30:00' for column 'col3' at row 1
|
||||||
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('15.13.2004 15.30','%d.%m.%Y %H.%i'));
|
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('15.13.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR HY000: Incorrect datetime value: '15.13.2004 15.30' for function str_to_time
|
ERROR HY000: Incorrect datetime value: '15.13.2004 15.30' for function str_to_date
|
||||||
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('00.00.0000','%d.%m.%Y'));
|
INSERT INTO t1 (col3) VALUES(STR_TO_DATE('00.00.0000','%d.%m.%Y'));
|
||||||
ERROR 22007: Incorrect datetime value: '0000-00-00' for column 'col3' at row 1
|
ERROR 22007: Incorrect datetime value: '0000-00-00' for column 'col3' at row 1
|
||||||
drop table t1;
|
drop table t1;
|
||||||
@ -1070,24 +1070,24 @@ create table t1 (col1 datetime);
|
|||||||
insert into t1 values(STR_TO_DATE('31.10.2004 15.30 abc','%d.%m.%Y %H.%i'));
|
insert into t1 values(STR_TO_DATE('31.10.2004 15.30 abc','%d.%m.%Y %H.%i'));
|
||||||
ERROR 22007: Truncated incorrect datetime value: '31.10.2004 15.30 abc'
|
ERROR 22007: Truncated incorrect datetime value: '31.10.2004 15.30 abc'
|
||||||
insert into t1 values(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
insert into t1 values(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_time
|
ERROR HY000: Incorrect datetime value: '32.10.2004 15.30' for function str_to_date
|
||||||
insert into t1 values(STR_TO_DATE('2004.12.12 22:22:33 AM','%Y.%m.%d %r'));
|
insert into t1 values(STR_TO_DATE('2004.12.12 22:22:33 AM','%Y.%m.%d %r'));
|
||||||
ERROR HY000: Incorrect time value: '22:22:33 AM' for function str_to_time
|
ERROR HY000: Incorrect time value: '22:22:33 AM' for function str_to_date
|
||||||
insert into t1 values(STR_TO_DATE('2004.12.12 abc','%Y.%m.%d %T'));
|
insert into t1 values(STR_TO_DATE('2004.12.12 abc','%Y.%m.%d %T'));
|
||||||
ERROR HY000: Incorrect time value: 'abc' for function str_to_time
|
ERROR HY000: Incorrect time value: 'abc' for function str_to_date
|
||||||
set sql_mode='';
|
set sql_mode='';
|
||||||
insert into t1 values(STR_TO_DATE('31.10.2004 15.30 abc','%d.%m.%Y %H.%i'));
|
insert into t1 values(STR_TO_DATE('31.10.2004 15.30 abc','%d.%m.%Y %H.%i'));
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1292 Truncated incorrect datetime value: '31.10.2004 15.30 abc'
|
Warning 1292 Truncated incorrect datetime value: '31.10.2004 15.30 abc'
|
||||||
insert into t1 values(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
insert into t1 values(STR_TO_DATE('32.10.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect datetime value: '32.10.2004 15.30' for function str_to_time
|
Error 1411 Incorrect datetime value: '32.10.2004 15.30' for function str_to_date
|
||||||
insert into t1 values(STR_TO_DATE('2004.12.12 22:22:33 AM','%Y.%m.%d %r'));
|
insert into t1 values(STR_TO_DATE('2004.12.12 22:22:33 AM','%Y.%m.%d %r'));
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect time value: '22:22:33 AM' for function str_to_time
|
Error 1411 Incorrect time value: '22:22:33 AM' for function str_to_date
|
||||||
insert into t1 values(STR_TO_DATE('2004.12.12 abc','%Y.%m.%d %T'));
|
insert into t1 values(STR_TO_DATE('2004.12.12 abc','%Y.%m.%d %T'));
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect time value: 'abc' for function str_to_time
|
Error 1411 Incorrect time value: 'abc' for function str_to_date
|
||||||
insert into t1 values(STR_TO_DATE('31.10.2004 15.30','%d.%m.%Y %H.%i'));
|
insert into t1 values(STR_TO_DATE('31.10.2004 15.30','%d.%m.%Y %H.%i'));
|
||||||
insert into t1 values(STR_TO_DATE('2004.12.12 11:22:33 AM','%Y.%m.%d %r'));
|
insert into t1 values(STR_TO_DATE('2004.12.12 11:22:33 AM','%Y.%m.%d %r'));
|
||||||
insert into t1 values(STR_TO_DATE('2004.12.12 10:22:59','%Y.%m.%d %T'));
|
insert into t1 values(STR_TO_DATE('2004.12.12 10:22:59','%Y.%m.%d %T'));
|
||||||
@ -1105,9 +1105,9 @@ select count(*) from t1 where STR_TO_DATE('2004.12.12 10:22:61','%Y.%m.%d %T') I
|
|||||||
count(*)
|
count(*)
|
||||||
7
|
7
|
||||||
Warnings:
|
Warnings:
|
||||||
Error 1411 Incorrect datetime value: '2004.12.12 10:22:61' for function str_to_time
|
Error 1411 Incorrect datetime value: '2004.12.12 10:22:61' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2004.12.12 10:22:61' for function str_to_time
|
Error 1411 Incorrect datetime value: '2004.12.12 10:22:61' for function str_to_date
|
||||||
Error 1411 Incorrect datetime value: '2004.12.12 10:22:61' for function str_to_time
|
Error 1411 Incorrect datetime value: '2004.12.12 10:22:61' for function str_to_date
|
||||||
drop table t1;
|
drop table t1;
|
||||||
create table t1 (col1 char(3), col2 integer);
|
create table t1 (col1 char(3), col2 integer);
|
||||||
insert into t1 (col1) values (cast(1000 as char(3)));
|
insert into t1 (col1) values (cast(1000 as char(3)));
|
||||||
|
20
mysql-test/suite/im/t/disabled.def
Normal file
20
mysql-test/suite/im/t/disabled.def
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
##############################################################################
|
||||||
|
#
|
||||||
|
# List the test cases that are to be disabled temporarily.
|
||||||
|
#
|
||||||
|
# Separate the test case name and the comment with ':'.
|
||||||
|
#
|
||||||
|
# <testcasename> : BUG#<xxxx> <date disabled> <disabler> <comment>
|
||||||
|
#
|
||||||
|
# Do not use any TAB characters for whitespace.
|
||||||
|
#
|
||||||
|
##############################################################################
|
||||||
|
im_options : Bug#20294 2006-07-24 stewart Instance manager test im_options fails randomly
|
||||||
|
im_daemon_life_cycle : Bug#20294 2007-05-14 alik Instance manager tests fail randomly
|
||||||
|
im_cmd_line : Bug#20294 2007-05-14 alik Instance manager tests fail randomly
|
||||||
|
im_utils : Bug#20294 2007-05-30 alik Instance manager tests fail randomly
|
||||||
|
im_instance_conf : Bug#20294 2007-05-30 alik Instance manager tests fail randomly
|
||||||
|
im_life_cycle : BUG#27851 Instance manager dies on ASSERT in ~Thread_registry() or from not being able to close a mysqld instance.
|
||||||
|
im_instance_conf : BUG#28743 Instance manager generates warnings in test suite
|
||||||
|
im_utils : BUG#28743 Instance manager generates warnings in test suite
|
||||||
|
|
@ -4,7 +4,7 @@
|
|||||||
#
|
#
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--source include/im_check_env.inc
|
--source suite/im/t/im_check_env.inc
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
@ -1,3 +1,5 @@
|
|||||||
|
let $UTIL=$MYSQL_TEST_DIR/suite/im/t;
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
#
|
#
|
||||||
# This file contains test for (1.2) test suite.
|
# This file contains test for (1.2) test suite.
|
||||||
@ -6,11 +8,11 @@
|
|||||||
#
|
#
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle im_daemon_life_cycle.imtest started.
|
--exec $UTIL/log.sh im_daemon_life_cycle im_daemon_life_cycle.imtest started.
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--source include/im_check_env.inc
|
--source suite/im/t/im_check_env.inc
|
||||||
|
|
||||||
# Turn on reconnect, not on by default anymore.
|
# Turn on reconnect, not on by default anymore.
|
||||||
--enable_reconnect
|
--enable_reconnect
|
||||||
@ -30,15 +32,15 @@
|
|||||||
#
|
#
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle Main-test: starting...
|
--exec $UTIL/log.sh im_daemon_life_cycle Main-test: starting...
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle Killing IM-main...
|
--exec $UTIL/log.sh im_daemon_life_cycle Killing IM-main...
|
||||||
--exec $MYSQL_TEST_DIR/t/kill_n_check.sh $IM_PATH_PID restarted 55 im_daemon_life_cycle
|
--exec $UTIL/kill_n_check.sh $IM_PATH_PID restarted 55 im_daemon_life_cycle
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle Waiting for IM-main to start accepting connections...
|
--exec $UTIL/log.sh im_daemon_life_cycle Waiting for IM-main to start accepting connections...
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_socket.sh $EXE_MYSQL $IM_PATH_SOCK $IM_USERNAME $IM_PASSWORD '' 55 im_daemon_life_cycle
|
--exec $UTIL/wait_for_socket.sh $EXE_MYSQL $IM_PATH_SOCK $IM_USERNAME $IM_PASSWORD '' 55 im_daemon_life_cycle
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle Main-test: done.
|
--exec $UTIL/log.sh im_daemon_life_cycle Main-test: done.
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
#
|
#
|
||||||
@ -55,29 +57,29 @@
|
|||||||
--echo -- Test for BUG#12751
|
--echo -- Test for BUG#12751
|
||||||
--echo --------------------------------------------------------------------
|
--echo --------------------------------------------------------------------
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle BUG12751: starting...
|
--exec $UTIL/log.sh im_daemon_life_cycle BUG12751: starting...
|
||||||
|
|
||||||
# 1. Start mysqld;
|
# 1. Start mysqld;
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle mysqld2: starting...
|
--exec $UTIL/log.sh im_daemon_life_cycle mysqld2: starting...
|
||||||
START INSTANCE mysqld2;
|
START INSTANCE mysqld2;
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle mysqld2: waiting to start...
|
--exec $UTIL/log.sh im_daemon_life_cycle mysqld2: waiting to start...
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_process.sh $IM_MYSQLD2_PATH_PID 55 started im_daemon_life_cycle
|
--exec $UTIL/wait_for_process.sh $IM_MYSQLD2_PATH_PID 55 started im_daemon_life_cycle
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle mysqld2: started.
|
--exec $UTIL/log.sh im_daemon_life_cycle mysqld2: started.
|
||||||
|
|
||||||
# 2. Restart IM-main;
|
# 2. Restart IM-main;
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle Killing IM-main...
|
--exec $UTIL/log.sh im_daemon_life_cycle Killing IM-main...
|
||||||
--exec $MYSQL_TEST_DIR/t/kill_n_check.sh $IM_PATH_PID restarted 55 im_daemon_life_cycle
|
--exec $UTIL/kill_n_check.sh $IM_PATH_PID restarted 55 im_daemon_life_cycle
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle Waiting for IM-main to start accepting connections...
|
--exec $UTIL/log.sh im_daemon_life_cycle Waiting for IM-main to start accepting connections...
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_socket.sh $EXE_MYSQL $IM_PATH_SOCK $IM_USERNAME $IM_PASSWORD '' 55 im_daemon_life_cycle
|
--exec $UTIL/wait_for_socket.sh $EXE_MYSQL $IM_PATH_SOCK $IM_USERNAME $IM_PASSWORD '' 55 im_daemon_life_cycle
|
||||||
|
|
||||||
# 3. Issue some statement -- connection should be re-established.
|
# 3. Issue some statement -- connection should be re-established.
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle Checking that IM-main processing commands...
|
--exec $UTIL/log.sh im_daemon_life_cycle Checking that IM-main processing commands...
|
||||||
|
|
||||||
--replace_column 2 STATE 3 VERSION_NUMBER 4 VERSION
|
--replace_column 2 STATE 3 VERSION_NUMBER 4 VERSION
|
||||||
SHOW INSTANCE STATUS mysqld1;
|
SHOW INSTANCE STATUS mysqld1;
|
||||||
@ -86,13 +88,13 @@ SHOW INSTANCE STATUS mysqld1;
|
|||||||
# So, if it we do not stop it, it will be stopped by mysql-test-run.pl with
|
# So, if it we do not stop it, it will be stopped by mysql-test-run.pl with
|
||||||
# warning.
|
# warning.
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle mysqld2: stopping...
|
--exec $UTIL/log.sh im_daemon_life_cycle mysqld2: stopping...
|
||||||
STOP INSTANCE mysqld2;
|
STOP INSTANCE mysqld2;
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle mysqld2: waiting to stop...
|
--exec $UTIL/log.sh im_daemon_life_cycle mysqld2: waiting to stop...
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_process.sh $IM_MYSQLD2_PATH_PID 55 stopped im_daemon_life_cycle
|
--exec $UTIL/wait_for_process.sh $IM_MYSQLD2_PATH_PID 55 stopped im_daemon_life_cycle
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle mysqld2: stopped.
|
--exec $UTIL/log.sh im_daemon_life_cycle mysqld2: stopped.
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/log.sh im_daemon_life_cycle BUG12751: done.
|
--exec $UTIL/log.sh im_daemon_life_cycle BUG12751: done.
|
@ -26,7 +26,7 @@
|
|||||||
#
|
#
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--source include/im_check_env.inc
|
--source suite/im/t/im_check_env.inc
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
#
|
#
|
@ -1,3 +1,5 @@
|
|||||||
|
let $UTIL=$MYSQL_TEST_DIR/suite/im/t;
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
#
|
#
|
||||||
# This file contains test for (1.1) test suite.
|
# This file contains test for (1.1) test suite.
|
||||||
@ -6,7 +8,7 @@
|
|||||||
#
|
#
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--source include/im_check_env.inc
|
--source suite/im/t/im_check_env.inc
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
#
|
#
|
||||||
@ -25,7 +27,7 @@
|
|||||||
|
|
||||||
START INSTANCE mysqld2;
|
START INSTANCE mysqld2;
|
||||||
# FIXME: START INSTANCE should be synchronous.
|
# FIXME: START INSTANCE should be synchronous.
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 started im_life_cycle
|
--exec $UTIL/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 started im_life_cycle
|
||||||
|
|
||||||
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
||||||
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
||||||
@ -58,7 +60,7 @@ SHOW VARIABLES LIKE 'port';
|
|||||||
|
|
||||||
STOP INSTANCE mysqld2;
|
STOP INSTANCE mysqld2;
|
||||||
# FIXME: STOP INSTANCE should be synchronous.
|
# FIXME: STOP INSTANCE should be synchronous.
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 stopped im_life_cycle
|
--exec $UTIL/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 stopped im_life_cycle
|
||||||
|
|
||||||
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
||||||
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
||||||
@ -121,7 +123,7 @@ STOP INSTANCE mysqld3;
|
|||||||
--echo -- 1.1.6.
|
--echo -- 1.1.6.
|
||||||
--echo --------------------------------------------------------------------
|
--echo --------------------------------------------------------------------
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/kill_n_check.sh $IM_MYSQLD1_PATH_PID restarted 30 im_life_cycle
|
--exec $UTIL/kill_n_check.sh $IM_MYSQLD1_PATH_PID restarted 30 im_life_cycle
|
||||||
|
|
||||||
# Give some time to IM to detect that mysqld was restarted. It should be
|
# Give some time to IM to detect that mysqld was restarted. It should be
|
||||||
# longer than monitoring interval.
|
# longer than monitoring interval.
|
||||||
@ -143,7 +145,7 @@ SHOW INSTANCES;
|
|||||||
|
|
||||||
START INSTANCE mysqld2;
|
START INSTANCE mysqld2;
|
||||||
# FIXME: START INSTANCE should be synchronous.
|
# FIXME: START INSTANCE should be synchronous.
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 started im_life_cycle
|
--exec $UTIL/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 started im_life_cycle
|
||||||
|
|
||||||
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
||||||
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
||||||
@ -151,7 +153,7 @@ START INSTANCE mysqld2;
|
|||||||
# mysqld has started.
|
# mysqld has started.
|
||||||
# SHOW INSTANCES;
|
# SHOW INSTANCES;
|
||||||
|
|
||||||
--exec $MYSQL_TEST_DIR/t/kill_n_check.sh $IM_MYSQLD2_PATH_PID killed 10 im_life_cycle
|
--exec $UTIL/kill_n_check.sh $IM_MYSQLD2_PATH_PID killed 10 im_life_cycle
|
||||||
|
|
||||||
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
# FIXME: Result of SHOW INSTANCES here is not deterministic unless START
|
||||||
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
# INSTANCE is synchronous. Even waiting for mysqld to start by looking at
|
@ -32,7 +32,7 @@
|
|||||||
#
|
#
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--source include/im_check_env.inc
|
--source suite/im/t/im_check_env.inc
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
#
|
#
|
@ -6,7 +6,9 @@
|
|||||||
#
|
#
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
--source include/im_check_env.inc
|
--source suite/im/t/im_check_env.inc
|
||||||
|
|
||||||
|
let $UTIL=$MYSQL_TEST_DIR/suite/im/t;
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
||||||
@ -31,10 +33,10 @@ SHOW INSTANCE OPTIONS mysqld2;
|
|||||||
#
|
#
|
||||||
|
|
||||||
START INSTANCE mysqld2;
|
START INSTANCE mysqld2;
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 started im_utils
|
--exec $UTIL/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 started im_utils
|
||||||
|
|
||||||
STOP INSTANCE mysqld2;
|
STOP INSTANCE mysqld2;
|
||||||
--exec $MYSQL_TEST_DIR/t/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 stopped im_utils
|
--exec $UTIL/wait_for_process.sh $IM_MYSQLD2_PATH_PID 30 stopped im_utils
|
||||||
|
|
||||||
#
|
#
|
||||||
# Check 'SHOW LOG FILES' command:
|
# Check 'SHOW LOG FILES' command:
|
@ -22,4 +22,4 @@ ndb_partition_error2 : HF is not sure if the test can work as internded on all
|
|||||||
#ndb_binlog_ddl_multi : BUG#18976 2006-04-10 kent CRBR: multiple binlog, second binlog may miss schema log events
|
#ndb_binlog_ddl_multi : BUG#18976 2006-04-10 kent CRBR: multiple binlog, second binlog may miss schema log events
|
||||||
#ndb_binlog_discover : bug#21806 2006-08-24
|
#ndb_binlog_discover : bug#21806 2006-08-24
|
||||||
#ndb_autodiscover3 : bug#21806
|
#ndb_autodiscover3 : bug#21806
|
||||||
ndb_autodiscover3 : Bug#20872 2007-07-15 ingo master*.err: miscellaneous error messages
|
#ndb_autodiscover3 : Bug#20872 2007-07-15 ingo master*.err: miscellaneous error messages
|
||||||
|
@ -17,6 +17,18 @@
|
|||||||
--echo --- All SQL functions should be rejected, otherwise BUG (see 18198)
|
--echo --- All SQL functions should be rejected, otherwise BUG (see 18198)
|
||||||
--echo -------------------------------------------------------------------------
|
--echo -------------------------------------------------------------------------
|
||||||
|
|
||||||
|
let $sqlfunc = ascii(col1);
|
||||||
|
let $valsqlfunc = ascii('a');
|
||||||
|
let $coltype = char(30);
|
||||||
|
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
||||||
|
# --source include/partition_blocked_sql_funcs.inc
|
||||||
|
|
||||||
|
let $sqlfunc = ord(col1);
|
||||||
|
let $valsqlfunc = ord('a');
|
||||||
|
let $coltype = char(30);
|
||||||
|
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
||||||
|
# --source include/partition_blocked_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = greatest(col1,15);
|
let $sqlfunc = greatest(col1,15);
|
||||||
let $valsqlfunc = greatest(1,15);
|
let $valsqlfunc = greatest(1,15);
|
||||||
let $coltype = int;
|
let $coltype = int;
|
||||||
@ -151,12 +163,6 @@ let $coltype = int;
|
|||||||
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
||||||
# --source include/partition_blocked_sql_funcs.inc
|
# --source include/partition_blocked_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = datediff(col1,col1);
|
|
||||||
let $valsqlfunc = datediff('1997-11-30 23:59:59','1997-12-31');
|
|
||||||
let $coltype = datetime;
|
|
||||||
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
|
||||||
# --source include/partition_blocked_sql_funcs.inc
|
|
||||||
|
|
||||||
let $sqlfunc = period_add(col1,5);
|
let $sqlfunc = period_add(col1,5);
|
||||||
let $valsqlfunc = period_add(9804,5);
|
let $valsqlfunc = period_add(9804,5);
|
||||||
let $coltype = datetime;
|
let $coltype = datetime;
|
||||||
@ -190,6 +196,12 @@ let $coltype = datetime;
|
|||||||
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
||||||
# --source include/partition_blocked_sql_funcs.inc
|
# --source include/partition_blocked_sql_funcs.inc
|
||||||
|
|
||||||
|
let $sqlfunc = weekofyear(col1);
|
||||||
|
let $valsqlfunc = weekofyear('2002-05-01');
|
||||||
|
let $coltype = datetime;
|
||||||
|
--source suite/parts/inc/partition_blocked_sql_funcs.inc
|
||||||
|
# --source include/partition_blocked_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = cast(col1 as signed);
|
let $sqlfunc = cast(col1 as signed);
|
||||||
let $valsqlfunc = cast(123 as signed);
|
let $valsqlfunc = cast(123 as signed);
|
||||||
let $coltype = varchar(30);
|
let $coltype = varchar(30);
|
||||||
|
@ -40,61 +40,42 @@ let $val4 = 15 ;
|
|||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
# --source include/partition_supported_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = ascii(col1);
|
|
||||||
let $valsqlfunc = ascii('5');
|
|
||||||
let $coltype = char(1);
|
|
||||||
let $infile = part_supported_sql_funcs_int_ch1.inc;
|
|
||||||
let $val1 = '1';
|
|
||||||
let $val2 = '9';
|
|
||||||
let $val3 = '3';
|
|
||||||
let $val4 = '8';
|
|
||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
|
||||||
|
|
||||||
let $sqlfunc = cast(ceiling(col1) as signed integer);
|
let $sqlfunc = ceiling(col1);
|
||||||
let $valsqlfunc = cast(ceiling(15) as signed integer);
|
let $valsqlfunc = ceiling(15);
|
||||||
let $coltype = float(7,4);
|
let $coltype = float(7,4);
|
||||||
let $infile = part_supported_sql_funcs_int_float.inc;
|
let $infile = part_supported_sql_funcs_int_float.inc;
|
||||||
let $val1 = 5.1230;
|
let $val1 = 5.1230;
|
||||||
let $val2 = 13.345;
|
let $val2 = 13.345;
|
||||||
let $val3 = 17.987;
|
let $val3 = 17.987;
|
||||||
let $val4 = 15.654 ;
|
let $val4 = 15.654 ;
|
||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
# DISABLED due to bug 30577
|
||||||
|
#--source suite/parts/inc/partition_supported_sql_funcs.inc
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
# --source include/partition_supported_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = cast(floor(col1) as signed);
|
let $sqlfunc = floor(col1);
|
||||||
let $valsqlfunc = cast(floor(15.123) as signed);
|
let $valsqlfunc = floor(15.123);
|
||||||
let $coltype = float(7,4);
|
let $coltype = float(7,4);
|
||||||
let $infile = part_supported_sql_funcs_int_float.inc;
|
let $infile = part_supported_sql_funcs_int_float.inc;
|
||||||
let $val1 = 5.1230;
|
let $val1 = 5.1230;
|
||||||
let $val2 = 13.345;
|
let $val2 = 13.345;
|
||||||
let $val3 = 17.987;
|
let $val3 = 17.987;
|
||||||
let $val4 = 15.654 ;
|
let $val4 = 15.654 ;
|
||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
# DISABLED due to bug 30577
|
||||||
|
#--source suite/parts/inc/partition_supported_sql_funcs.inc
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
# --source include/partition_supported_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = cast(mod(col1,10) as signed);
|
let $sqlfunc = mod(col1,10);
|
||||||
let $valsqlfunc = cast(mod(15,10) as signed);
|
let $valsqlfunc = mod(15,10);
|
||||||
let $coltype = float(7,4);
|
let $coltype = int;
|
||||||
let $infile = part_supported_sql_funcs_int_float.inc;
|
let $infile = part_supported_sql_funcs_int_int.inc;
|
||||||
let $val1 = 5.0000;
|
let $val1 = 5;
|
||||||
let $val2 = 19;
|
let $val2 = 19;
|
||||||
let $val3 = 17;
|
let $val3 = 17;
|
||||||
let $val4 = 15 ;
|
let $val4 = 15 ;
|
||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
# --source include/partition_supported_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = ord(col1);
|
|
||||||
let $valsqlfunc = ord('a');
|
|
||||||
let $coltype = char(3);
|
|
||||||
let $infile = part_supported_sql_funcs_int_ch1.inc;
|
|
||||||
let $val1 = '1';
|
|
||||||
let $val2 = '9';
|
|
||||||
let $val3 = '3';
|
|
||||||
let $val4 = '8';
|
|
||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
|
||||||
|
|
||||||
let $sqlfunc = day(col1);
|
let $sqlfunc = day(col1);
|
||||||
let $valsqlfunc = day('2006-12-21');
|
let $valsqlfunc = day('2006-12-21');
|
||||||
let $coltype = date;
|
let $coltype = date;
|
||||||
@ -243,6 +224,18 @@ let $val4 = '2006-02-06';
|
|||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
# --source include/partition_supported_sql_funcs.inc
|
||||||
|
|
||||||
|
# DATEDIFF() is implemented as (TO_DAYS(d1) - TO_DAYS(d2))
|
||||||
|
let $sqlfunc = datediff(col1, '2006-01-01');
|
||||||
|
let $valsqlfunc = datediff('2006-02-02', '2006-01-01');
|
||||||
|
let $coltype = date;
|
||||||
|
let $infile = part_supported_sql_funcs_int_date.inc;
|
||||||
|
let $val1 = '2006-02-03';
|
||||||
|
let $val2 = '2006-01-17';
|
||||||
|
let $val3 = '2006-01-25';
|
||||||
|
let $val4 = '2006-02-06';
|
||||||
|
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
||||||
|
# --source include/partition_supported_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = weekday(col1);
|
let $sqlfunc = weekday(col1);
|
||||||
let $valsqlfunc = weekday('2006-10-14');
|
let $valsqlfunc = weekday('2006-10-14');
|
||||||
let $coltype = date;
|
let $coltype = date;
|
||||||
@ -254,17 +247,6 @@ let $val4 = '2006-02-06';
|
|||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
# --source include/partition_supported_sql_funcs.inc
|
||||||
|
|
||||||
let $sqlfunc = weekofyear(col1);
|
|
||||||
let $valsqlfunc = weekofyear('2006-02-14');
|
|
||||||
let $coltype = date;
|
|
||||||
let $infile = part_supported_sql_funcs_int_date.inc;
|
|
||||||
let $val1 = '2006-01-03';
|
|
||||||
let $val2 = '2006-03-17';
|
|
||||||
let $val3 = '2006-05-25';
|
|
||||||
let $val4 = '2006-09-06';
|
|
||||||
--source suite/parts/inc/partition_supported_sql_funcs.inc
|
|
||||||
# --source include/partition_supported_sql_funcs.inc
|
|
||||||
|
|
||||||
let $sqlfunc = year(col1)-1990;
|
let $sqlfunc = year(col1)-1990;
|
||||||
let $valsqlfunc = year('2005-10-14')-1990;
|
let $valsqlfunc = year('2005-10-14')-1990;
|
||||||
let $coltype = date;
|
let $coltype = date;
|
||||||
|
@ -43,16 +43,16 @@ SELECT IF(9999 - 1000 + 1 > @max_row, @max_row , 9999 - 1000 + 1)
|
|||||||
ALTER TABLE t1 ADD PARTITION (PARTITION part2);
|
ALTER TABLE t1 ADD PARTITION (PARTITION part2);
|
||||||
#
|
#
|
||||||
--echo # 1.1.2 Assign HASH partitioning
|
--echo # 1.1.2 Assign HASH partitioning
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(YEAR(f_date) AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(YEAR(f_date));
|
||||||
--source include/partition_layout.inc
|
--source include/partition_layout.inc
|
||||||
--source suite/parts/inc/partition_check_read1.inc
|
--source suite/parts/inc/partition_check_read1.inc
|
||||||
#
|
#
|
||||||
--echo # 1.1.3 Assign other HASH partitioning to already partitioned table
|
--echo # 1.1.3 Assign other HASH partitioning to already partitioned table
|
||||||
--echo # + test and switch back + test
|
--echo # + test and switch back + test
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(f_varchar AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(DAYOFYEAR(f_date));
|
||||||
--source include/partition_layout.inc
|
--source include/partition_layout.inc
|
||||||
--source suite/parts/inc/partition_check_read1.inc
|
--source suite/parts/inc/partition_check_read1.inc
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(YEAR(f_date) AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(YEAR(f_date));
|
||||||
--source include/partition_layout.inc
|
--source include/partition_layout.inc
|
||||||
--source suite/parts/inc/partition_check_read1.inc
|
--source suite/parts/inc/partition_check_read1.inc
|
||||||
#
|
#
|
||||||
|
@ -36,8 +36,9 @@
|
|||||||
eval $insert_first_half;
|
eval $insert_first_half;
|
||||||
# Possible/Expected return codes for ALTER TABLE ...
|
# Possible/Expected return codes for ALTER TABLE ...
|
||||||
# 0
|
# 0
|
||||||
# 1491: A PRIMARY KEY need to include all fields in the partition function
|
# 1030: ER_GET_ERRNO
|
||||||
# A UNIQUE INDEX need to include all fields in the partition function
|
# 1500: ER_UNIQUE_KEY_NEED_ALL_FIELDS_IN_PF
|
||||||
|
# 1504: ER_DROP_PARTITION_NON_EXISTENT
|
||||||
--disable_abort_on_error
|
--disable_abort_on_error
|
||||||
eval $alter;
|
eval $alter;
|
||||||
--enable_abort_on_error
|
--enable_abort_on_error
|
||||||
@ -47,11 +48,11 @@ if ($no_debug)
|
|||||||
}
|
}
|
||||||
eval SET @my_errno = $mysql_errno;
|
eval SET @my_errno = $mysql_errno;
|
||||||
let $run_test= `SELECT @my_errno = 0`;
|
let $run_test= `SELECT @my_errno = 0`;
|
||||||
let $unexpected_error= `SELECT @my_errno NOT IN (0,1030,1491,1495)`;
|
let $unexpected_error= `SELECT @my_errno NOT IN (0,1030,1500,1504)`;
|
||||||
if ($unexpected_error)
|
if ($unexpected_error)
|
||||||
{
|
{
|
||||||
--echo # The last command got an unexepected error response.
|
--echo # The last command got an unexepected error response.
|
||||||
--echo # Expected/handled SQL codes are 0,1030,1491,1495
|
--echo # Expected/handled SQL codes are 0,1030,1500,1504
|
||||||
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
||||||
--echo # Sorry, have to abort.
|
--echo # Sorry, have to abort.
|
||||||
exit;
|
exit;
|
||||||
|
@ -15,8 +15,7 @@
|
|||||||
--echo -------------------------------------------------------------------------
|
--echo -------------------------------------------------------------------------
|
||||||
--echo --- $sqlfunc in partition with coltype $coltype
|
--echo --- $sqlfunc in partition with coltype $coltype
|
||||||
--echo -------------------------------------------------------------------------
|
--echo -------------------------------------------------------------------------
|
||||||
--echo must all fail! (delete 0 and comment char, if bug fixed)
|
--echo must all fail!
|
||||||
--disable_abort_on_error
|
|
||||||
--disable_warnings
|
--disable_warnings
|
||||||
drop table if exists t1 ;
|
drop table if exists t1 ;
|
||||||
drop table if exists t2 ;
|
drop table if exists t2 ;
|
||||||
@ -26,32 +25,31 @@ drop table if exists t5 ;
|
|||||||
drop table if exists t6 ;
|
drop table if exists t6 ;
|
||||||
--enable_warnings
|
--enable_warnings
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval create table t1 (col1 $coltype) engine=$engine
|
eval create table t1 (col1 $coltype) engine=$engine
|
||||||
partition by range($sqlfunc)
|
partition by range($sqlfunc)
|
||||||
(partition p0 values less than (15),
|
(partition p0 values less than (15),
|
||||||
partition p1 values less than (31));
|
partition p1 values less than (31));
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval create table t2 (col1 $coltype) engine=$engine
|
eval create table t2 (col1 $coltype) engine=$engine
|
||||||
partition by list($sqlfunc)
|
partition by list($sqlfunc)
|
||||||
(partition p0 values in (1,2,3,4,5,6,7,8,9,10),
|
(partition p0 values in (1,2,3,4,5,6,7,8,9,10),
|
||||||
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
||||||
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval create table t3 (col1 $coltype) engine=$engine
|
eval create table t3 (col1 $coltype) engine=$engine
|
||||||
partition by hash($sqlfunc);
|
partition by hash($sqlfunc);
|
||||||
--enable_abort_on_error
|
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval create table t4 (colint int, col1 $coltype) engine=$engine
|
eval create table t4 (colint int, col1 $coltype) engine=$engine
|
||||||
partition by range(colint)
|
partition by range(colint)
|
||||||
subpartition by hash($sqlfunc) subpartitions 2
|
subpartition by hash($sqlfunc) subpartitions 2
|
||||||
(partition p0 values less than (15),
|
(partition p0 values less than (15),
|
||||||
partition p1 values less than (31));
|
partition p1 values less than (31));
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval create table t5 (colint int, col1 $coltype) engine=$engine
|
eval create table t5 (colint int, col1 $coltype) engine=$engine
|
||||||
partition by list(colint)
|
partition by list(colint)
|
||||||
subpartition by hash($sqlfunc) subpartitions 2
|
subpartition by hash($sqlfunc) subpartitions 2
|
||||||
@ -59,7 +57,7 @@ subpartition by hash($sqlfunc) subpartitions 2
|
|||||||
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
||||||
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval create table t6 (colint int, col1 $coltype) engine=$engine
|
eval create table t6 (colint int, col1 $coltype) engine=$engine
|
||||||
partition by range(colint)
|
partition by range(colint)
|
||||||
(partition p0 values less than ($valsqlfunc),
|
(partition p0 values less than ($valsqlfunc),
|
||||||
@ -75,50 +73,44 @@ drop table if exists t55 ;
|
|||||||
drop table if exists t66 ;
|
drop table if exists t66 ;
|
||||||
--enable_warnings
|
--enable_warnings
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
|
||||||
eval create table t11 (col1 $coltype) engine=$engine ;
|
eval create table t11 (col1 $coltype) engine=$engine ;
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
|
||||||
eval create table t22 (col1 $coltype) engine=$engine ;
|
eval create table t22 (col1 $coltype) engine=$engine ;
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
|
||||||
eval create table t33 (col1 $coltype) engine=$engine ;
|
eval create table t33 (col1 $coltype) engine=$engine ;
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
|
||||||
eval create table t44 (colint int, col1 $coltype) engine=$engine ;
|
eval create table t44 (colint int, col1 $coltype) engine=$engine ;
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
|
||||||
eval create table t55 (colint int, col1 $coltype) engine=$engine ;
|
eval create table t55 (colint int, col1 $coltype) engine=$engine ;
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
|
||||||
eval create table t66 (colint int, col1 $coltype) engine=$engine ;
|
eval create table t66 (colint int, col1 $coltype) engine=$engine ;
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval alter table t11
|
eval alter table t11
|
||||||
partition by range($sqlfunc)
|
partition by range($sqlfunc)
|
||||||
(partition p0 values less than (15),
|
(partition p0 values less than (15),
|
||||||
partition p1 values less than (31));
|
partition p1 values less than (31));
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval alter table t22
|
eval alter table t22
|
||||||
partition by list($sqlfunc)
|
partition by list($sqlfunc)
|
||||||
(partition p0 values in (1,2,3,4,5,6,7,8,9,10),
|
(partition p0 values in (1,2,3,4,5,6,7,8,9,10),
|
||||||
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
||||||
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
||||||
|
|
||||||
#--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval alter table t33
|
eval alter table t33
|
||||||
partition by hash($sqlfunc);
|
partition by hash($sqlfunc);
|
||||||
--enable_abort_on_error
|
--enable_abort_on_error
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval alter table t44
|
eval alter table t44
|
||||||
partition by range(colint)
|
partition by range(colint)
|
||||||
subpartition by hash($sqlfunc) subpartitions 2
|
subpartition by hash($sqlfunc) subpartitions 2
|
||||||
(partition p0 values less than (15),
|
(partition p0 values less than (15),
|
||||||
partition p1 values less than (31));
|
partition p1 values less than (31));
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval alter table t55
|
eval alter table t55
|
||||||
partition by list(colint)
|
partition by list(colint)
|
||||||
subpartition by hash($sqlfunc) subpartitions 2
|
subpartition by hash($sqlfunc) subpartitions 2
|
||||||
@ -126,7 +118,7 @@ subpartition by hash($sqlfunc) subpartitions 2
|
|||||||
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
partition p1 values in (11,12,13,14,15,16,17,18,19,20),
|
||||||
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
partition p2 values in (21,22,23,24,25,26,27,28,29,30));
|
||||||
|
|
||||||
--error 0,ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED,ER_PARSE_ERROR
|
||||||
eval alter table t66
|
eval alter table t66
|
||||||
partition by range(colint)
|
partition by range(colint)
|
||||||
(partition p0 values less than ($valsqlfunc),
|
(partition p0 values less than ($valsqlfunc),
|
||||||
|
@ -156,8 +156,8 @@ if ($run)
|
|||||||
# partitioning mechanism.
|
# partitioning mechanism.
|
||||||
# Sideeffect: Attempt to INSERT one record
|
# Sideeffect: Attempt to INSERT one record
|
||||||
# DUPLICATE KEY will appear if we have UNIQUE columns
|
# DUPLICATE KEY will appear if we have UNIQUE columns
|
||||||
# 1022: Can't write; duplicate key in table 't1' UIDX/PK(f_int1)
|
# 1022: ER_DUP_KEY
|
||||||
# 1062: Duplicate entry '2' for key 1 UIDX/PK(f_int2)
|
# 1062: ER_DUP_ENTRY
|
||||||
--disable_abort_on_error
|
--disable_abort_on_error
|
||||||
INSERT INTO t1 (f_int1, f_int2, f_char1, f_char2, f_charbig)
|
INSERT INTO t1 (f_int1, f_int2, f_char1, f_char2, f_charbig)
|
||||||
SELECT f_int1, f_int1, CAST(f_int1 AS CHAR),
|
SELECT f_int1, f_int1, CAST(f_int1 AS CHAR),
|
||||||
@ -200,7 +200,8 @@ if ($any_unique)
|
|||||||
## 1.3.1 Check, if f_int1 is UNIQUE
|
## 1.3.1 Check, if f_int1 is UNIQUE
|
||||||
# Sideeffect: Attempt to INSERT one record
|
# Sideeffect: Attempt to INSERT one record
|
||||||
# DUPLICATE KEY will appear if we have UNIQUE columns
|
# DUPLICATE KEY will appear if we have UNIQUE columns
|
||||||
# 1022: Can't write; duplicate key in table 't1' UIDX/PK
|
# 1022: ER_DUP_KEY
|
||||||
|
# 1062: ER_DUP_ENTRY
|
||||||
--disable_abort_on_error
|
--disable_abort_on_error
|
||||||
INSERT INTO t1 (f_int1, f_int2, f_char1, f_char2, f_charbig)
|
INSERT INTO t1 (f_int1, f_int2, f_char1, f_char2, f_charbig)
|
||||||
SELECT f_int1, 2 * @max_row + f_int1, CAST((2 * @max_row + f_int1) AS CHAR),
|
SELECT f_int1, 2 * @max_row + f_int1, CAST((2 * @max_row + f_int1) AS CHAR),
|
||||||
@ -494,8 +495,9 @@ WHERE f_charbig = '#SINGLE#' AND f_int1 IN (-1,@cur_value);
|
|||||||
# 4.7 Insert one record with such a big value for f_int1, so that in case
|
# 4.7 Insert one record with such a big value for f_int1, so that in case
|
||||||
# - f_int1 is used within the partitioning algorithm
|
# - f_int1 is used within the partitioning algorithm
|
||||||
# - we use range partitioning
|
# - we use range partitioning
|
||||||
# we get error ER_NO_PARTITION_FOR_GIVEN_VALUE (1514)
|
# we get error ER_NO_PARTITION_FOR_GIVEN_VALUE (1523)
|
||||||
# "Table has no partition for value ...."
|
# "Table has no partition for value ...."
|
||||||
|
# or ER_SAME_NAME_PARTITION (1514)
|
||||||
--disable_abort_on_error
|
--disable_abort_on_error
|
||||||
eval INSERT INTO t1 SET f_int1 = @max_int_4 , f_int2 = @max_int_4, f_charbig = '#$max_int_4##';
|
eval INSERT INTO t1 SET f_int1 = @max_int_4 , f_int2 = @max_int_4, f_charbig = '#$max_int_4##';
|
||||||
--enable_abort_on_error
|
--enable_abort_on_error
|
||||||
@ -504,11 +506,11 @@ if ($no_debug)
|
|||||||
--disable_query_log
|
--disable_query_log
|
||||||
}
|
}
|
||||||
eval SET @my_errno = $mysql_errno;
|
eval SET @my_errno = $mysql_errno;
|
||||||
let $unexpected_error= `SELECT @my_errno NOT IN (0,1505,1514)`;
|
let $unexpected_error= `SELECT @my_errno NOT IN (0,1514,1523)`;
|
||||||
if ($unexpected_error)
|
if ($unexpected_error)
|
||||||
{
|
{
|
||||||
--echo # The last command got an unexepected error response.
|
--echo # The last command got an unexepected error response.
|
||||||
--echo # Expected/handled SQL codes are 0,1514
|
--echo # Expected/handled SQL codes are 0,1514,1523
|
||||||
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
||||||
--echo # Sorry, have to abort.
|
--echo # Sorry, have to abort.
|
||||||
exit;
|
exit;
|
||||||
@ -555,8 +557,8 @@ INSERT t1 SET f_int1 = 0 , f_int2 = 0,
|
|||||||
# f1 "=" NULL is a delicate value which might stress the partitioning
|
# f1 "=" NULL is a delicate value which might stress the partitioning
|
||||||
# mechanism if the result of the expression in the partitioning algorithm
|
# mechanism if the result of the expression in the partitioning algorithm
|
||||||
# becomes NULL.
|
# becomes NULL.
|
||||||
# Not: This INSERT will fail, if f_int1 is PRIMARY KEY or UNIQUE INDEX
|
# This INSERT will fail, if f_int1 is PRIMARY KEY or UNIQUE INDEX
|
||||||
# 1048: Column 'f_int1' cannot be null
|
# 1048: ER_BAD_NULL_ERROR
|
||||||
--disable_abort_on_error
|
--disable_abort_on_error
|
||||||
|
|
||||||
INSERT INTO t1
|
INSERT INTO t1
|
||||||
|
@ -49,7 +49,7 @@ select * from t2;
|
|||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
eval create table t3 (a date not null, primary key(a)) engine=$engine
|
eval create table t3 (a date not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -69,7 +69,7 @@ select * from t3;
|
|||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a date not null, primary key(a)) engine=$engine
|
eval create table t4 (a date not null, primary key(a)) engine=$engine
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3),
|
partition quarter1 values in (1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
|
@ -46,7 +46,7 @@ select * from t2;
|
|||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
eval create table t3 (a datetime not null, primary key(a)) engine=$engine
|
eval create table t3 (a datetime not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -66,7 +66,7 @@ select * from t3;
|
|||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a datetime not null, primary key(a)) engine=$engine
|
eval create table t4 (a datetime not null, primary key(a)) engine=$engine
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3),
|
partition quarter1 values in (1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
|
@ -47,8 +47,15 @@ dec $count;
|
|||||||
select count(*) from t2;
|
select count(*) from t2;
|
||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
|
# Bug 30577: FLOOR() and CEILING() not usable as partition functions
|
||||||
|
# Partition functions are required to return INT_RESULT; FLOOR() and
|
||||||
|
# CEILING() do not, unless they have an INT argument. Disable this
|
||||||
|
# portion of the test until bug 30577 is fixed.
|
||||||
|
|
||||||
|
--disable_parsing
|
||||||
|
|
||||||
eval create table t3 (a decimal(18,9) not null, primary key(a)) engine=$engine
|
eval create table t3 (a decimal(18,9) not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(floor(a) as signed)) subpartition by key (a) subpartitions 2 (
|
partition by range (floor(a)) subpartition by key (a) subpartitions 2 (
|
||||||
partition pa2 values less than (2),
|
partition pa2 values less than (2),
|
||||||
partition pa4 values less than (4),
|
partition pa4 values less than (4),
|
||||||
partition pa6 values less than (6),
|
partition pa6 values less than (6),
|
||||||
@ -70,7 +77,7 @@ select count(*) from t3;
|
|||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a decimal(18,9) not null, primary key(a)) engine=$engine
|
eval create table t4 (a decimal(18,9) not null, primary key(a)) engine=$engine
|
||||||
partition by list (cast(floor(a) as signed)) subpartition by key (a) subpartitions 2 (
|
partition by list (floor(a)) subpartition by key (a) subpartitions 2 (
|
||||||
partition pa2 values in (1,2),
|
partition pa2 values in (1,2),
|
||||||
partition pa4 values in (3,4),
|
partition pa4 values in (3,4),
|
||||||
partition pa6 values in (5,6),
|
partition pa6 values in (5,6),
|
||||||
@ -90,3 +97,6 @@ dec $count;
|
|||||||
--enable_query_log
|
--enable_query_log
|
||||||
select count(*) from t4;
|
select count(*) from t4;
|
||||||
drop table t4;
|
drop table t4;
|
||||||
|
|
||||||
|
# Disabled due to Bug 30577
|
||||||
|
--enable_parsing
|
||||||
|
@ -29,9 +29,9 @@ let $partitioning= ;
|
|||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
let $partitioning= PARTITION BY HASH(f_int1) PARTITIONS 2;
|
let $partitioning= PARTITION BY HASH(f_int1) PARTITIONS 2;
|
||||||
|
--disable_query_log
|
||||||
if ($with_directories)
|
if ($with_directories)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY HASH(f_int1) PARTITIONS 2
|
'PARTITION BY HASH(f_int1) PARTITIONS 2
|
||||||
(PARTITION p1
|
(PARTITION p1
|
||||||
@ -39,7 +39,6 @@ $index_directory,
|
|||||||
PARTITION p2
|
PARTITION p2
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
@ -47,6 +46,7 @@ $column_list
|
|||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -54,9 +54,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY KEY
|
#----------- PARTITION BY KEY
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY KEY(f_int1) PARTITIONS 5';
|
'PARTITION BY KEY(f_int1) PARTITIONS 5';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
@ -76,7 +76,6 @@ PARTITION p4,
|
|||||||
PARTITION p5
|
PARTITION p5
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
@ -84,6 +83,7 @@ $column_list
|
|||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -91,9 +91,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY LIST
|
#----------- PARTITION BY LIST
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY LIST(MOD(f_int1,4))
|
'PARTITION BY LIST(MOD(f_int1,4))
|
||||||
(PARTITION part_3 VALUES IN (-3)
|
(PARTITION part_3 VALUES IN (-3)
|
||||||
@ -119,6 +119,7 @@ $column_list
|
|||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -126,9 +127,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY RANGE
|
#----------- PARTITION BY RANGE
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
#--disable_query_log
|
|
||||||
eval SET @aux = 'PARTITION BY RANGE(f_int1)
|
eval SET @aux = 'PARTITION BY RANGE(f_int1)
|
||||||
(PARTITION parta VALUES LESS THAN (0)
|
(PARTITION parta VALUES LESS THAN (0)
|
||||||
$index_directory,
|
$index_directory,
|
||||||
@ -143,13 +144,13 @@ $data_directory,
|
|||||||
PARTITION partf VALUES LESS THAN $MAX_VALUE
|
PARTITION partf VALUES LESS THAN $MAX_VALUE
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
#--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -157,9 +158,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY RANGE -- SUBPARTITION BY HASH
|
#----------- PARTITION BY RANGE -- SUBPARTITION BY HASH
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY RANGE(f_int1 DIV 2) SUBPARTITION BY HASH(f_int1) SUBPARTITIONS 2
|
'PARTITION BY RANGE(f_int1 DIV 2) SUBPARTITION BY HASH(f_int1) SUBPARTITIONS 2
|
||||||
(PARTITION parta VALUES LESS THAN (0)
|
(PARTITION parta VALUES LESS THAN (0)
|
||||||
@ -171,13 +172,13 @@ PARTITION partd VALUES LESS THAN $MAX_VALUE
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -185,9 +186,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY RANGE -- SUBPARTITION BY KEY
|
#----------- PARTITION BY RANGE -- SUBPARTITION BY KEY
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux = 'PARTITION BY RANGE(f_int1) SUBPARTITION BY KEY(f_int1)
|
eval SET @aux = 'PARTITION BY RANGE(f_int1) SUBPARTITION BY KEY(f_int1)
|
||||||
(PARTITION part1 VALUES LESS THAN (0)
|
(PARTITION part1 VALUES LESS THAN (0)
|
||||||
$data_directory
|
$data_directory
|
||||||
@ -202,13 +203,13 @@ $index_directory
|
|||||||
PARTITION part4 VALUES LESS THAN $MAX_VALUE
|
PARTITION part4 VALUES LESS THAN $MAX_VALUE
|
||||||
(SUBPARTITION subpart41, SUBPARTITION subpart42))';
|
(SUBPARTITION subpart41, SUBPARTITION subpart42))';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -216,9 +217,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY LIST -- SUBPARTITION BY HASH
|
#----------- PARTITION BY LIST -- SUBPARTITION BY HASH
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY LIST(ABS(MOD(f_int1,3))) SUBPARTITION BY HASH(f_int1 + 1)
|
'PARTITION BY LIST(ABS(MOD(f_int1,3))) SUBPARTITION BY HASH(f_int1 + 1)
|
||||||
(PARTITION part1 VALUES IN (0)
|
(PARTITION part1 VALUES IN (0)
|
||||||
@ -246,13 +247,13 @@ eval SET @aux =
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory))';
|
$index_directory))';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
|
@ -48,8 +48,15 @@ select count(*) from t2;
|
|||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
|
|
||||||
|
# Bug 30577: FLOOR() and CEILING() not usable as partition functions
|
||||||
|
# Partition functions are required to return INT_RESULT; FLOOR() and
|
||||||
|
# CEILING() do not, unless they have an INT argument. Disable this
|
||||||
|
# portion of the test until bug 30577 is fixed.
|
||||||
|
|
||||||
|
--disable_parsing
|
||||||
|
|
||||||
eval create table t3 (a double not null, primary key(a)) engine=$engine
|
eval create table t3 (a double not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(floor(a) as signed)) subpartition by key (a) subpartitions 3 (
|
partition by range (floor(a)) subpartition by key (a) subpartitions 3 (
|
||||||
partition pa1 values less than (3),
|
partition pa1 values less than (3),
|
||||||
partition pa3 values less than (6),
|
partition pa3 values less than (6),
|
||||||
partition pa10 values less than (10)
|
partition pa10 values less than (10)
|
||||||
@ -69,7 +76,7 @@ select * from t3;
|
|||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a double not null, primary key(a)) engine=$engine
|
eval create table t4 (a double not null, primary key(a)) engine=$engine
|
||||||
partition by list (cast(floor(a) as signed)) subpartition by key (a) subpartitions 3 (
|
partition by list (floor(a)) subpartition by key (a) subpartitions 3 (
|
||||||
partition pa1 values in (1,2,3),
|
partition pa1 values in (1,2,3),
|
||||||
partition pa3 values in (4,5,6),
|
partition pa3 values in (4,5,6),
|
||||||
partition pa10 values in (7,8,9,10)
|
partition pa10 values in (7,8,9,10)
|
||||||
@ -87,3 +94,6 @@ dec $count;
|
|||||||
select count(*) from t4;
|
select count(*) from t4;
|
||||||
select * from t4;
|
select * from t4;
|
||||||
drop table t4;
|
drop table t4;
|
||||||
|
|
||||||
|
# Disabled due to Bug 30577
|
||||||
|
--enable_parsing
|
||||||
|
@ -53,7 +53,7 @@ eval create table t3 (a enum (
|
|||||||
'M','N','O','P','Q','R','S','T','U','V','W','X',
|
'M','N','O','P','Q','R','S','T','U','V','W','X',
|
||||||
'Y','Z'
|
'Y','Z'
|
||||||
) not null, primary key(a)) engine=$engine
|
) not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(a as unsigned)) subpartition by key (a) subpartitions 3 (
|
partition by range (a) subpartition by key (a) subpartitions 3 (
|
||||||
partition pa9 values less than (10),
|
partition pa9 values less than (10),
|
||||||
partition pa18 values less than (19),
|
partition pa18 values less than (19),
|
||||||
partition pa27 values less than (28),
|
partition pa27 values less than (28),
|
||||||
@ -72,28 +72,3 @@ select count(*) from t3;
|
|||||||
select * from t3;
|
select * from t3;
|
||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a enum (
|
|
||||||
'1','2','3','4','5','6','7','8','9','0',
|
|
||||||
'A','B','C','D','E','F','G','H','I','J','K','L',
|
|
||||||
'M','N','O','P','Q','R','S','T','U','V','W','X',
|
|
||||||
'Y','Z'
|
|
||||||
) not null, primary key(a)) engine=$engine
|
|
||||||
partition by list (cast(a as unsigned)) subpartition by key (a) subpartitions 3 (
|
|
||||||
partition pa9 values in (1,2,3,4,5,6,7,8,9),
|
|
||||||
partition pa18 values in (10,11,12,13,14,15,16,17,18),
|
|
||||||
partition pa27 values in (19,20,21,22,23,24,25,26,27),
|
|
||||||
partition pa36 values in (28,29,30,31,32,33,34,35,36)
|
|
||||||
);
|
|
||||||
show create table t4;
|
|
||||||
let $letter=36;
|
|
||||||
--echo $count inserts;
|
|
||||||
#--disable_query_log
|
|
||||||
while ($letter)
|
|
||||||
{
|
|
||||||
#eval insert into t4 values ($letter);
|
|
||||||
dec $letter;
|
|
||||||
}
|
|
||||||
select count(*) from t4;
|
|
||||||
select * from t4;
|
|
||||||
drop table t4;
|
|
||||||
|
|
||||||
|
@ -51,8 +51,15 @@ dec $count;
|
|||||||
select count(*) from t2;
|
select count(*) from t2;
|
||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
|
# Bug 30577: FLOOR() and CEILING() not usable as partition functions
|
||||||
|
# Partition functions are required to return INT_RESULT; FLOOR() and
|
||||||
|
# CEILING() do not, unless they have an INT argument. Disable this
|
||||||
|
# portion of the test until bug 30577 is fixed.
|
||||||
|
|
||||||
|
--disable_parsing
|
||||||
|
|
||||||
eval create table t3 (a float not null, primary key(a)) engine=$engine
|
eval create table t3 (a float not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(floor(a) as signed)) subpartition by key (a) subpartitions 3 (
|
partition by range (floor(a)) subpartition by key (a) subpartitions 3 (
|
||||||
partition pa1 values less than (3),
|
partition pa1 values less than (3),
|
||||||
partition pa3 values less than (6),
|
partition pa3 values less than (6),
|
||||||
partition pa10 values less than (10)
|
partition pa10 values less than (10)
|
||||||
@ -72,7 +79,7 @@ select * from t3;
|
|||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a float not null, primary key(a)) engine=$engine
|
eval create table t4 (a float not null, primary key(a)) engine=$engine
|
||||||
partition by list (cast(floor(a) as signed)) subpartition by key (a) subpartitions 3 (
|
partition by list (floor(a)) subpartition by key (a) subpartitions 3 (
|
||||||
partition pa1 values in (1,2,3),
|
partition pa1 values in (1,2,3),
|
||||||
partition pa3 values in (4,5,6),
|
partition pa3 values in (4,5,6),
|
||||||
partition pa10 values in (7,8,9,10)
|
partition pa10 values in (7,8,9,10)
|
||||||
@ -90,3 +97,6 @@ dec $count;
|
|||||||
select count(*) from t4;
|
select count(*) from t4;
|
||||||
select * from t4;
|
select * from t4;
|
||||||
drop table t4;
|
drop table t4;
|
||||||
|
|
||||||
|
# Disabled due to Bug 30577
|
||||||
|
--enable_parsing
|
||||||
|
@ -56,6 +56,7 @@ eval INSERT INTO t0_definition SET state = 'old',
|
|||||||
file_list = $file_list;
|
file_list = $file_list;
|
||||||
|
|
||||||
# Print the create table statement into the protocol
|
# Print the create table statement into the protocol
|
||||||
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
SELECT create_command FROM t0_definition WHERE state = 'old';
|
SELECT create_command FROM t0_definition WHERE state = 'old';
|
||||||
if ($do_file_tests)
|
if ($do_file_tests)
|
||||||
{
|
{
|
||||||
|
@ -55,6 +55,7 @@ let $run= `SELECT @aux`;
|
|||||||
if ($run)
|
if ($run)
|
||||||
{
|
{
|
||||||
--vertical_results
|
--vertical_results
|
||||||
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
SELECT state,
|
SELECT state,
|
||||||
REPLACE(create_command,'\n',' ') AS "Table definition",
|
REPLACE(create_command,'\n',' ') AS "Table definition",
|
||||||
REPLACE(file_list ,'\n',' ') AS "File list"
|
REPLACE(file_list ,'\n',' ') AS "File list"
|
||||||
|
@ -44,9 +44,9 @@ let $partitioning= ;
|
|||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
let $partitioning= PARTITION BY HASH(f_int1) PARTITIONS 2;
|
let $partitioning= PARTITION BY HASH(f_int1) PARTITIONS 2;
|
||||||
|
--disable_query_log
|
||||||
if ($with_directories)
|
if ($with_directories)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY HASH(f_int1) PARTITIONS 2
|
'PARTITION BY HASH(f_int1) PARTITIONS 2
|
||||||
(PARTITION p1
|
(PARTITION p1
|
||||||
@ -56,7 +56,6 @@ PARTITION p2
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
@ -64,6 +63,7 @@ $column_list
|
|||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -71,15 +71,14 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY KEY
|
#----------- PARTITION BY KEY
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY KEY(f_int1) PARTITIONS 5';
|
'PARTITION BY KEY(f_int1) PARTITIONS 5';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
if ($with_directories)
|
if ($with_directories)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY HASH(f_int1) PARTITIONS 5
|
'PARTITION BY HASH(f_int1) PARTITIONS 5
|
||||||
(PARTITION p1
|
(PARTITION p1
|
||||||
@ -98,7 +97,6 @@ PARTITION p5
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
@ -106,6 +104,7 @@ $column_list
|
|||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -113,9 +112,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY LIST
|
#----------- PARTITION BY LIST
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY LIST(MOD(f_int1,4))
|
'PARTITION BY LIST(MOD(f_int1,4))
|
||||||
(PARTITION part_3 VALUES IN (-3)
|
(PARTITION part_3 VALUES IN (-3)
|
||||||
@ -141,6 +140,7 @@ $column_list
|
|||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -148,9 +148,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY RANGE
|
#----------- PARTITION BY RANGE
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
#--disable_query_log
|
|
||||||
eval SET @aux = 'PARTITION BY RANGE(f_int1)
|
eval SET @aux = 'PARTITION BY RANGE(f_int1)
|
||||||
(PARTITION parta VALUES LESS THAN (0)
|
(PARTITION parta VALUES LESS THAN (0)
|
||||||
$data_directory
|
$data_directory
|
||||||
@ -171,13 +171,13 @@ PARTITION partf VALUES LESS THAN $MAX_VALUE
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
#--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -185,9 +185,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY RANGE -- SUBPARTITION BY HASH
|
#----------- PARTITION BY RANGE -- SUBPARTITION BY HASH
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY RANGE(f_int1 DIV 2) SUBPARTITION BY HASH(f_int1) SUBPARTITIONS 2
|
'PARTITION BY RANGE(f_int1 DIV 2) SUBPARTITION BY HASH(f_int1) SUBPARTITIONS 2
|
||||||
(PARTITION parta VALUES LESS THAN (0)
|
(PARTITION parta VALUES LESS THAN (0)
|
||||||
@ -203,13 +203,13 @@ PARTITION partd VALUES LESS THAN $MAX_VALUE
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -217,9 +217,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY RANGE -- SUBPARTITION BY KEY
|
#----------- PARTITION BY RANGE -- SUBPARTITION BY KEY
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux = 'PARTITION BY RANGE(f_int1) SUBPARTITION BY KEY(f_int1)
|
eval SET @aux = 'PARTITION BY RANGE(f_int1) SUBPARTITION BY KEY(f_int1)
|
||||||
(PARTITION part1 VALUES LESS THAN (0)
|
(PARTITION part1 VALUES LESS THAN (0)
|
||||||
$data_directory
|
$data_directory
|
||||||
@ -238,13 +238,13 @@ $data_directory
|
|||||||
$index_directory
|
$index_directory
|
||||||
(SUBPARTITION subpart41, SUBPARTITION subpart42))';
|
(SUBPARTITION subpart41, SUBPARTITION subpart42))';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -252,9 +252,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY LIST -- SUBPARTITION BY HASH
|
#----------- PARTITION BY LIST -- SUBPARTITION BY HASH
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY LIST(ABS(MOD(f_int1,3))) SUBPARTITION BY HASH(f_int1 + 1)
|
'PARTITION BY LIST(ABS(MOD(f_int1,3))) SUBPARTITION BY HASH(f_int1 + 1)
|
||||||
(PARTITION part1 VALUES IN (0)
|
(PARTITION part1 VALUES IN (0)
|
||||||
@ -290,13 +290,13 @@ eval SET @aux =
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory))';
|
$index_directory))';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
@ -304,9 +304,9 @@ DROP TABLE t1;
|
|||||||
--source suite/parts/inc/partition_check_drop.inc
|
--source suite/parts/inc/partition_check_drop.inc
|
||||||
|
|
||||||
#----------- PARTITION BY LIST -- SUBPARTITION BY KEY
|
#----------- PARTITION BY LIST -- SUBPARTITION BY KEY
|
||||||
|
--disable_query_log
|
||||||
if ($with_partitioning)
|
if ($with_partitioning)
|
||||||
{
|
{
|
||||||
--disable_query_log
|
|
||||||
eval SET @aux =
|
eval SET @aux =
|
||||||
'PARTITION BY LIST(ABS(MOD(f_int1,2)))
|
'PARTITION BY LIST(ABS(MOD(f_int1,2)))
|
||||||
SUBPARTITION BY KEY(f_int1) SUBPARTITIONS $sub_part_no
|
SUBPARTITION BY KEY(f_int1) SUBPARTITIONS $sub_part_no
|
||||||
@ -320,13 +320,13 @@ SUBPARTITION BY KEY(f_int1) SUBPARTITIONS $sub_part_no
|
|||||||
$data_directory
|
$data_directory
|
||||||
$index_directory)';
|
$index_directory)';
|
||||||
let $partitioning= `SELECT @aux`;
|
let $partitioning= `SELECT @aux`;
|
||||||
--enable_query_log
|
|
||||||
}
|
}
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
$unique
|
$unique
|
||||||
)
|
)
|
||||||
$partitioning;
|
$partitioning;
|
||||||
|
--enable_query_log
|
||||||
eval $insert_all;
|
eval $insert_all;
|
||||||
--source suite/parts/inc/partition_check.inc
|
--source suite/parts/inc/partition_check.inc
|
||||||
# --source include/partition_check.inc
|
# --source include/partition_check.inc
|
||||||
|
@ -43,41 +43,3 @@ insert into t2 values ('1,2,3'),('2,3,4'),('3,4,5'),('4,5,6'),('5,6,7'),('6,7,8'
|
|||||||
select count(*) from t2;
|
select count(*) from t2;
|
||||||
select * from t2 order by a;
|
select * from t2 order by a;
|
||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
eval create table t3 (a set (
|
|
||||||
'1','2','3','4','5','6','7','8','9','0'
|
|
||||||
) not null, primary key(a)) engine=$engine
|
|
||||||
partition by range (cast(a as unsigned)) subpartition by key (a) subpartitions 3 (
|
|
||||||
partition pa9 values less than (10),
|
|
||||||
partition pa18 values less than (19),
|
|
||||||
partition pa27 values less than (28),
|
|
||||||
partition pa36 values less than (37),
|
|
||||||
partition pa64 values less than (65),
|
|
||||||
partition pa128 values less than (129),
|
|
||||||
partition pa256 values less than (257),
|
|
||||||
partition pa512 values less than (513),
|
|
||||||
partition pa768 values less than (769),
|
|
||||||
partition pa1024 values less than (1025)
|
|
||||||
);
|
|
||||||
show create table t3;
|
|
||||||
#insert into t3 values ('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9'),('0');
|
|
||||||
#insert into t3 values ('1,2'),('2,3'),('3,4'),('4,5'),('5,6'),('6,7'),('7,8'),('8,9'),('9,0'),('0,1');
|
|
||||||
#insert into t3 values ('1,2,3'),('2,3,4'),('3,4,5'),('4,5,6'),('5,6,7'),('6,7,8'),('7,8,9'),('8,9,0'),('9,0,1'),('0,1,2');
|
|
||||||
select count(*) from t3;
|
|
||||||
select * from t3 order by a;
|
|
||||||
drop table t3;
|
|
||||||
|
|
||||||
eval create table t4 (a set (
|
|
||||||
'1','2','3') not null, primary key(a)) engine=$engine
|
|
||||||
partition by list (cast(a as unsigned)) subpartition by key (a) subpartitions 3 (
|
|
||||||
partition pa9 values in (1,2,3,4,5,6,7,8,9),
|
|
||||||
partition pa18 values in (10,11,12,13,14,15,16,17,18),
|
|
||||||
partition pa27 values in (19,20,21,22,23,24,25,26,27)
|
|
||||||
);
|
|
||||||
show create table t4;
|
|
||||||
#insert into t4 values ('1'),('2'),('3');
|
|
||||||
#insert into t4 values ('1,2'),('2,3'),('3,1');
|
|
||||||
#insert into t4 values ('1,2,3');
|
|
||||||
select count(*) from t4;
|
|
||||||
select * from t4 order by a;
|
|
||||||
drop table t4;
|
|
||||||
|
@ -83,14 +83,9 @@ eval insert into t3 values ($val1);
|
|||||||
eval insert into t3 values ($val2);
|
eval insert into t3 values ($val2);
|
||||||
eval insert into t3 values ($val3);
|
eval insert into t3 values ($val3);
|
||||||
|
|
||||||
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
eval load data infile '../std_data_ln/parts/$infile' into table t4;
|
||||||
eval load data infile '$MYSQL_TEST_DIR/suite/parts/inc/$infile' into table t4;
|
eval load data infile '../std_data_ln/parts/$infile' into table t5;
|
||||||
|
eval load data infile '../std_data_ln/parts/$infile' into table t6;
|
||||||
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
|
||||||
eval load data infile '$MYSQL_TEST_DIR/suite/parts/inc/$infile' into table t5;
|
|
||||||
|
|
||||||
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
|
||||||
eval load data infile '$MYSQL_TEST_DIR/suite/parts/inc/$infile' into table t6;
|
|
||||||
|
|
||||||
eval select $sqlfunc from t1 order by col1;
|
eval select $sqlfunc from t1 order by col1;
|
||||||
|
|
||||||
|
@ -331,13 +331,13 @@ $column_list
|
|||||||
PARTITION BY RANGE(f_int1)
|
PARTITION BY RANGE(f_int1)
|
||||||
( PARTITION part1 VALUES LESS THAN (NULL),
|
( PARTITION part1 VALUES LESS THAN (NULL),
|
||||||
PARTITION part2 VALUES LESS THAN (1000));
|
PARTITION part2 VALUES LESS THAN (1000));
|
||||||
--echo # 3.5.1.2 VALUE LESS THAN (CAST(NULL AS SIGNED INTEGER)) is not allowed
|
--echo # 3.5.1.2 VALUE LESS THAN (NULL) is not allowed
|
||||||
--error 1064
|
--error 1064
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
)
|
)
|
||||||
PARTITION BY RANGE(f_int1)
|
PARTITION BY RANGE(f_int1)
|
||||||
( PARTITION part1 VALUES LESS THAN (CAST(NULL AS SIGNED INTEGER)),
|
( PARTITION part1 VALUES LESS THAN (NULL),
|
||||||
PARTITION part2 VALUES LESS THAN (1000));
|
PARTITION part2 VALUES LESS THAN (1000));
|
||||||
--echo # 3.5.2 NULL in LIST partitioning clause
|
--echo # 3.5.2 NULL in LIST partitioning clause
|
||||||
--echo # 3.5.2.1 VALUE IN (NULL)
|
--echo # 3.5.2.1 VALUE IN (NULL)
|
||||||
@ -349,14 +349,14 @@ PARTITION BY LIST(MOD(f_int1,2))
|
|||||||
PARTITION part2 VALUES IN (0),
|
PARTITION part2 VALUES IN (0),
|
||||||
PARTITION part3 VALUES IN (1));
|
PARTITION part3 VALUES IN (1));
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
--echo # 3.5.2.2 VALUE IN (CAST(NULL AS SIGNED INTEGER))
|
--echo # 3.5.2.2 VALUE IN (NULL)
|
||||||
# Attention: It is intended that there is no partition with
|
# Attention: It is intended that there is no partition with
|
||||||
# VALUES IN (0), because there was a time where NULL was treated as zero
|
# VALUES IN (0), because there was a time where NULL was treated as zero
|
||||||
eval CREATE TABLE t1 (
|
eval CREATE TABLE t1 (
|
||||||
$column_list
|
$column_list
|
||||||
)
|
)
|
||||||
PARTITION BY LIST(MOD(f_int1,2))
|
PARTITION BY LIST(MOD(f_int1,2))
|
||||||
( PARTITION part1 VALUES IN (CAST(NULL AS SIGNED INTEGER)),
|
( PARTITION part1 VALUES IN (NULL),
|
||||||
PARTITION part3 VALUES IN (1));
|
PARTITION part3 VALUES IN (1));
|
||||||
--source suite/parts/inc/partition_layout_check1.inc
|
--source suite/parts/inc/partition_layout_check1.inc
|
||||||
# --source include/partition_layout_check1.inc
|
# --source include/partition_layout_check1.inc
|
||||||
@ -368,7 +368,7 @@ eval CREATE TABLE t1 (
|
|||||||
$column_list
|
$column_list
|
||||||
)
|
)
|
||||||
PARTITION BY LIST(MOD(f_int1,2))
|
PARTITION BY LIST(MOD(f_int1,2))
|
||||||
( PARTITION part1 VALUES IN (CAST(NULL AS SIGNED INTEGER)),
|
( PARTITION part1 VALUES IN (NULL),
|
||||||
PARTITION part2 VALUES IN (0),
|
PARTITION part2 VALUES IN (0),
|
||||||
PARTITION part3 VALUES IN (1));
|
PARTITION part3 VALUES IN (1));
|
||||||
--source suite/parts/inc/partition_layout_check1.inc
|
--source suite/parts/inc/partition_layout_check1.inc
|
||||||
|
@ -28,15 +28,15 @@ eval SET @my_errno= $mysql_errno ;
|
|||||||
let $run= `SELECT @my_errno = 0`;
|
let $run= `SELECT @my_errno = 0`;
|
||||||
# Expected error codes are
|
# Expected error codes are
|
||||||
# 0
|
# 0
|
||||||
# 1064 ERROR 42000: You have an error in your SQL syntax
|
# 1064 ER_PARSE_ERROR
|
||||||
# Reason: assign -1 partitions
|
# Reason: assign -1 partitions
|
||||||
# 1486 ERROR HY000: Too many partitions (including subpartitions) were defined
|
# 1496 ER_TOO_MANY_PARTITIONS_ERROR
|
||||||
# 1491 ERROR HY000: Number of partitions = 0 is not an allowed value
|
# 1501 ER_NO_PARTS_ERROR
|
||||||
let $unexpected_error= `SELECT @my_errno NOT IN (0,1064,1487,1492)`;
|
let $unexpected_error= `SELECT @my_errno NOT IN (0,1064,1496,1501)`;
|
||||||
if ($unexpected_error)
|
if ($unexpected_error)
|
||||||
{
|
{
|
||||||
--echo # The last command got an unexepected error response.
|
--echo # The last command got an unexepected error response.
|
||||||
--echo # Expected/handled SQL codes are 0,1064,1487,1492
|
--echo # Expected/handled SQL codes are 0,1064,1496,1501
|
||||||
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
||||||
--echo # Sorry, have to abort.
|
--echo # Sorry, have to abort.
|
||||||
exit;
|
exit;
|
||||||
@ -66,15 +66,15 @@ eval SET @my_errno= $mysql_errno ;
|
|||||||
let $run= `SELECT @my_errno = 0`;
|
let $run= `SELECT @my_errno = 0`;
|
||||||
# Expected error codes are
|
# Expected error codes are
|
||||||
# 0
|
# 0
|
||||||
# 1064 ERROR 42000: You have an error in your SQL syntax
|
# 1064 ER_PARSE_ERROR
|
||||||
# Reason: assign -1 subpartitions
|
# Reason: assign -1 partitions
|
||||||
# 1487 ERROR HY000: Too many partitions (including subpartitions) were defined
|
# 1496 ER_TOO_MANY_PARTITIONS_ERROR
|
||||||
# 1492 ERROR HY000: Number of partitions = 0 is not an allowed value
|
# 1501 ER_NO_PARTS_ERROR
|
||||||
let $unexpected_error= `SELECT @my_errno NOT IN (0,1064,1487,1492)`;
|
let $unexpected_error= `SELECT @my_errno NOT IN (0,1064,1496,1501)`;
|
||||||
if ($unexpected_error)
|
if ($unexpected_error)
|
||||||
{
|
{
|
||||||
--echo # The last command got an unexepected error response.
|
--echo # The last command got an unexepected error response.
|
||||||
--echo # Expected/handled SQL codes are 0,1064,1487,1492
|
--echo # Expected/handled SQL codes are 0,1064,1496,1501
|
||||||
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
SELECT '# SQL code we got was: ' AS "", @my_errno AS "";
|
||||||
--echo # Sorry, have to abort.
|
--echo # Sorry, have to abort.
|
||||||
exit;
|
exit;
|
||||||
|
@ -46,7 +46,7 @@ select * from t2;
|
|||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
eval create table t3 (a time not null, primary key(a)) engine=$engine
|
eval create table t3 (a time not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(second(a) as unsigned)) subpartition by key (a)
|
partition by range (second(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (16),
|
partition quarter1 values less than (16),
|
||||||
partition quarter2 values less than (31),
|
partition quarter2 values less than (31),
|
||||||
@ -66,7 +66,7 @@ select * from t3;
|
|||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a time not null, primary key(a)) engine=$engine
|
eval create table t4 (a time not null, primary key(a)) engine=$engine
|
||||||
partition by list (cast(second(a) as unsigned)) subpartition by key (a)
|
partition by list (second(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15),
|
partition quarter1 values in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15),
|
||||||
partition quarter2 values in (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30),
|
partition quarter2 values in (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30),
|
||||||
|
@ -46,7 +46,7 @@ select * from t2;
|
|||||||
drop table t2;
|
drop table t2;
|
||||||
|
|
||||||
eval create table t3 (a timestamp not null, primary key(a)) engine=$engine
|
eval create table t3 (a timestamp not null, primary key(a)) engine=$engine
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -66,7 +66,7 @@ select * from t3;
|
|||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
eval create table t4 (a timestamp not null, primary key(a)) engine=$engine
|
eval create table t4 (a timestamp not null, primary key(a)) engine=$engine
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (0,1,2,3),
|
partition quarter1 values in (0,1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
|
@ -12,6 +12,16 @@
|
|||||||
# Change: #
|
# Change: #
|
||||||
################################################################################
|
################################################################################
|
||||||
|
|
||||||
|
|
||||||
|
--echo
|
||||||
|
--echo This test relies on the CAST() function for partitioning, which
|
||||||
|
--echo is not allowed. Not deleting it yet, as it may have some useful
|
||||||
|
--echo bits in it. See Bug #30581, "partition_value tests use disallowed
|
||||||
|
--echo CAST() function"
|
||||||
|
--echo
|
||||||
|
|
||||||
|
--disable_parsing
|
||||||
|
|
||||||
--echo
|
--echo
|
||||||
--echo #========================================================================
|
--echo #========================================================================
|
||||||
--echo # Calculation of "exotic" results within the partition function
|
--echo # Calculation of "exotic" results within the partition function
|
||||||
@ -155,3 +165,5 @@ VALUES(NULL,NULL,NULL,NULL,NULL);
|
|||||||
eval SELECT COUNT(*) = 1 FROM t1 WHERE f_char2 IS NULL;
|
eval SELECT COUNT(*) = 1 FROM t1 WHERE f_char2 IS NULL;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
#
|
#
|
||||||
|
|
||||||
|
--enable_parsing
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -64,7 +64,7 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -78,15 +78,15 @@ id select_type table partitions type possible_keys key key_len ref rows Extra
|
|||||||
ALTER TABLE t1 ADD PARTITION (PARTITION part2);
|
ALTER TABLE t1 ADD PARTITION (PARTITION part2);
|
||||||
ERROR HY000: Partition management on a not partitioned table is not possible
|
ERROR HY000: Partition management on a not partitioned table is not possible
|
||||||
# 1.1.2 Assign HASH partitioning
|
# 1.1.2 Assign HASH partitioning
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(YEAR(f_date) AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(YEAR(f_date));
|
||||||
SHOW CREATE TABLE t1;
|
SHOW CREATE TABLE t1;
|
||||||
Table Create Table
|
Table Create Table
|
||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -95,51 +95,30 @@ id select_type table partitions type possible_keys key key_len ref rows Extra
|
|||||||
# check read row by row success: 1
|
# check read row by row success: 1
|
||||||
# 1.1.3 Assign other HASH partitioning to already partitioned table
|
# 1.1.3 Assign other HASH partitioning to already partitioned table
|
||||||
# + test and switch back + test
|
# + test and switch back + test
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(f_varchar AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(DAYOFYEAR(f_date));
|
||||||
Warnings:
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '20 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '19 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '18 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '17 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '16 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '15 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '14 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '13 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '12 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '11 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '10 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '9 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '8 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '7 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '6 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '5 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '4 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '3 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '2 '
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '1 '
|
|
||||||
SHOW CREATE TABLE t1;
|
SHOW CREATE TABLE t1;
|
||||||
Table Create Table
|
Table Create Table
|
||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(f_varchar AS SIGNED INTEGER)) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (DAYOFYEAR(f_date)) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
# check read single success: 1
|
# check read single success: 1
|
||||||
# check read all success: 1
|
# check read all success: 1
|
||||||
# check read row by row success: 1
|
# check read row by row success: 1
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(YEAR(f_date) AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(YEAR(f_date));
|
||||||
SHOW CREATE TABLE t1;
|
SHOW CREATE TABLE t1;
|
||||||
Table Create Table
|
Table Create Table
|
||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -158,9 +137,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -177,9 +156,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -193,9 +172,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB, PARTITION p7 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB, PARTITION p7 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -221,9 +200,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -236,9 +215,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 4 Using where
|
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 4 Using where
|
||||||
@ -251,9 +230,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
||||||
@ -266,9 +245,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -281,9 +260,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -296,9 +275,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
||||||
@ -311,9 +290,9 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -331,7 +310,7 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -370,7 +349,7 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -392,8 +371,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -416,8 +395,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -435,8 +414,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -454,8 +433,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB, PARTITION p7 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB, PARTITION p7 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -480,8 +459,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB, PARTITION p6 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
||||||
@ -498,8 +477,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB, PARTITION p5 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -516,8 +495,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB, PARTITION p4 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 10 Using where
|
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 10 Using where
|
||||||
@ -534,8 +513,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB, PARTITION part2 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -552,8 +531,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB, PARTITION part7 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -570,8 +549,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB, PARTITION part1 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
||||||
@ -588,8 +567,8 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = InnoDB) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -610,7 +589,7 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
|
@ -64,9 +64,9 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -80,17 +80,17 @@ id select_type table partitions type possible_keys key key_len ref rows Extra
|
|||||||
ALTER TABLE t1 ADD PARTITION (PARTITION part2);
|
ALTER TABLE t1 ADD PARTITION (PARTITION part2);
|
||||||
ERROR HY000: Partition management on a not partitioned table is not possible
|
ERROR HY000: Partition management on a not partitioned table is not possible
|
||||||
# 1.1.2 Assign HASH partitioning
|
# 1.1.2 Assign HASH partitioning
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(YEAR(f_date) AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(YEAR(f_date));
|
||||||
SHOW CREATE TABLE t1;
|
SHOW CREATE TABLE t1;
|
||||||
Table Create Table
|
Table Create Table
|
||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -99,55 +99,34 @@ id select_type table partitions type possible_keys key key_len ref rows Extra
|
|||||||
# check read row by row success: 1
|
# check read row by row success: 1
|
||||||
# 1.1.3 Assign other HASH partitioning to already partitioned table
|
# 1.1.3 Assign other HASH partitioning to already partitioned table
|
||||||
# + test and switch back + test
|
# + test and switch back + test
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(f_varchar AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(DAYOFYEAR(f_date));
|
||||||
Warnings:
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '20'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '19'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '18'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '17'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '16'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '15'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '14'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '13'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '12'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '11'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '10'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '90'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '80'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '70'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '60'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '50'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '40'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '30'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '20'
|
|
||||||
Warning 1292 Truncated incorrect INTEGER value: '10'
|
|
||||||
SHOW CREATE TABLE t1;
|
SHOW CREATE TABLE t1;
|
||||||
Table Create Table
|
Table Create Table
|
||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(f_varchar AS SIGNED INTEGER)) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (DAYOFYEAR(f_date)) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
# check read single success: 1
|
# check read single success: 1
|
||||||
# check read all success: 1
|
# check read all success: 1
|
||||||
# check read row by row success: 1
|
# check read row by row success: 1
|
||||||
ALTER TABLE t1 PARTITION BY HASH(CAST(YEAR(f_date) AS SIGNED INTEGER));
|
ALTER TABLE t1 PARTITION BY HASH(YEAR(f_date));
|
||||||
SHOW CREATE TABLE t1;
|
SHOW CREATE TABLE t1;
|
||||||
Table Create Table
|
Table Create Table
|
||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -166,15 +145,15 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -191,17 +170,17 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -215,25 +194,25 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM, PARTITION p7 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM, PARTITION p7 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -259,23 +238,23 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -288,21 +267,21 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 4 Using where
|
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 4 Using where
|
||||||
@ -315,19 +294,19 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
||||||
@ -340,17 +319,17 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -363,15 +342,15 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part1 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -384,13 +363,13 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
||||||
@ -403,11 +382,11 @@ Table Create Table
|
|||||||
t1 CREATE TABLE `t1` (
|
t1 CREATE TABLE `t1` (
|
||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) (PARTITION p0 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (YEAR(f_date)) (PARTITION p0 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -425,9 +404,9 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_date` date DEFAULT NULL,
|
`f_date` date DEFAULT NULL,
|
||||||
`f_varchar` varchar(30) DEFAULT NULL
|
`f_varchar` varchar(30) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
EXPLAIN PARTITIONS SELECT COUNT(*) FROM t1 WHERE f_date = '1000-02-10';
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -460,9 +439,9 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -484,10 +463,10 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -510,14 +489,14 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -535,16 +514,16 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -562,24 +541,24 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM, PARTITION p7 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM, PARTITION p7 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 p6 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -604,22 +583,22 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM, PARTITION p6 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p6.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p6.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 4 Using where
|
||||||
@ -636,20 +615,20 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM, PARTITION p5 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p5.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p5.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 3 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 3 Using where
|
||||||
@ -666,18 +645,18 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM, PARTITION p4 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p4.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p4.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 10 Using where
|
1 SIMPLE t1 p4 ALL NULL NULL NULL NULL 10 Using where
|
||||||
@ -694,16 +673,16 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part2.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part2.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 5 Using where
|
||||||
@ -720,14 +699,14 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM, PARTITION part7 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part7.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part7.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
1 SIMPLE t1 part7 ALL NULL NULL NULL NULL 7 Using where
|
||||||
@ -744,12 +723,12 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#part1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#part1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 10 Using where
|
||||||
@ -766,10 +745,10 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (f_int1) (PARTITION p0 ENGINE = MyISAM) */
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1#P#p0.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1#P#p0.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.par
|
MYSQLTEST_VARDIR/master-data/test/t1.par
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 p0 ALL NULL NULL NULL NULL 20 Using where
|
||||||
@ -790,9 +769,9 @@ t1 CREATE TABLE `t1` (
|
|||||||
`f_char2` char(20) DEFAULT NULL,
|
`f_char2` char(20) DEFAULT NULL,
|
||||||
`f_charbig` varchar(1000) DEFAULT NULL
|
`f_charbig` varchar(1000) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYD
|
MYSQLTEST_VARDIR/master-data/test/t1.MYD
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.MYI
|
MYSQLTEST_VARDIR/master-data/test/t1.MYI
|
||||||
/data0/mysql/mysql-5.1-build/mysql-test/var/master-data/test/t1.frm
|
MYSQLTEST_VARDIR/master-data/test/t1.frm
|
||||||
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
EXPLAIN PARTITIONS SELECT COUNT(*) <> 1 FROM t1 WHERE f_int1 = 3;
|
||||||
id select_type table partitions type possible_keys key key_len ref rows Extra
|
id select_type table partitions type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
1 SIMPLE t1 NULL ALL NULL NULL NULL NULL 20 Using where
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -186,7 +186,7 @@ a
|
|||||||
1971-01-01 00:00:59
|
1971-01-01 00:00:59
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a timestamp not null, primary key(a)) engine='InnoDB'
|
create table t3 (a timestamp not null, primary key(a)) engine='InnoDB'
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -198,7 +198,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = InnoDB) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t3 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
insert into t3 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
||||||
insert into t3 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
insert into t3 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
||||||
@ -233,7 +233,7 @@ a
|
|||||||
1970-12-01 00:00:00
|
1970-12-01 00:00:00
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a timestamp not null, primary key(a)) engine='InnoDB'
|
create table t4 (a timestamp not null, primary key(a)) engine='InnoDB'
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (0,1,2,3),
|
partition quarter1 values in (0,1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
@ -245,7 +245,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (0,1,2,3) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (0,1,2,3) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = InnoDB) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t4 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
insert into t4 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
||||||
insert into t4 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
insert into t4 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
||||||
@ -517,7 +517,7 @@ a
|
|||||||
1970-03-28
|
1970-03-28
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a date not null, primary key(a)) engine='InnoDB'
|
create table t3 (a date not null, primary key(a)) engine='InnoDB'
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -529,7 +529,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` date NOT NULL,
|
`a` date NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = InnoDB) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t3 values (adddate(19700101,interval 12-1 month));
|
insert into t3 values (adddate(19700101,interval 12-1 month));
|
||||||
insert into t3 values (adddate(19700101,interval 11-1 month));
|
insert into t3 values (adddate(19700101,interval 11-1 month));
|
||||||
@ -562,7 +562,7 @@ a
|
|||||||
1970-12-01
|
1970-12-01
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a date not null, primary key(a)) engine='InnoDB'
|
create table t4 (a date not null, primary key(a)) engine='InnoDB'
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3),
|
partition quarter1 values in (1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
@ -574,7 +574,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` date NOT NULL,
|
`a` date NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = InnoDB) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t4 values (adddate(19700101,interval 12-1 month));
|
insert into t4 values (adddate(19700101,interval 12-1 month));
|
||||||
insert into t4 values (adddate(19700101,interval 11-1 month));
|
insert into t4 values (adddate(19700101,interval 11-1 month));
|
||||||
@ -794,7 +794,7 @@ a
|
|||||||
00:01:59
|
00:01:59
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a time not null, primary key(a)) engine='InnoDB'
|
create table t3 (a time not null, primary key(a)) engine='InnoDB'
|
||||||
partition by range (cast(second(a) as unsigned)) subpartition by key (a)
|
partition by range (second(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (16),
|
partition quarter1 values less than (16),
|
||||||
partition quarter2 values less than (31),
|
partition quarter2 values less than (31),
|
||||||
@ -806,7 +806,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` time NOT NULL,
|
`a` time NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(second(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (16) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (31) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (46) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (61) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (second(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (16) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (31) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (46) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (61) ENGINE = InnoDB) */
|
||||||
59 inserts;
|
59 inserts;
|
||||||
insert into t3 values (100000+59);
|
insert into t3 values (100000+59);
|
||||||
insert into t3 values (100000+58);
|
insert into t3 values (100000+58);
|
||||||
@ -933,7 +933,7 @@ a
|
|||||||
10:00:59
|
10:00:59
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a time not null, primary key(a)) engine='InnoDB'
|
create table t4 (a time not null, primary key(a)) engine='InnoDB'
|
||||||
partition by list (cast(second(a) as unsigned)) subpartition by key (a)
|
partition by list (second(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15),
|
partition quarter1 values in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15),
|
||||||
partition quarter2 values in (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30),
|
partition quarter2 values in (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30),
|
||||||
@ -945,7 +945,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` time NOT NULL,
|
`a` time NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(second(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (31,32,33,34,35,36,37,38,39,40,41,42,43,44,45) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (46,47,48,49,50,51,52,53,54,55,56,57,58,59,60) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (second(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (31,32,33,34,35,36,37,38,39,40,41,42,43,44,45) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (46,47,48,49,50,51,52,53,54,55,56,57,58,59,60) ENGINE = InnoDB) */
|
||||||
59 inserts;
|
59 inserts;
|
||||||
insert into t4 values (100000+59);
|
insert into t4 values (100000+59);
|
||||||
insert into t4 values (100000+58);
|
insert into t4 values (100000+58);
|
||||||
@ -1259,7 +1259,7 @@ a
|
|||||||
1970-01-01 00:00:59
|
1970-01-01 00:00:59
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a datetime not null, primary key(a)) engine='InnoDB'
|
create table t3 (a datetime not null, primary key(a)) engine='InnoDB'
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -1271,7 +1271,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` datetime NOT NULL,
|
`a` datetime NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = InnoDB, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = InnoDB, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = InnoDB, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = InnoDB) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t3 values (adddate(19700101000000,interval 12-1 month));
|
insert into t3 values (adddate(19700101000000,interval 12-1 month));
|
||||||
insert into t3 values (adddate(19700101000000,interval 11-1 month));
|
insert into t3 values (adddate(19700101000000,interval 11-1 month));
|
||||||
@ -1304,7 +1304,7 @@ a
|
|||||||
1970-12-01 00:00:00
|
1970-12-01 00:00:00
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a datetime not null, primary key(a)) engine='InnoDB'
|
create table t4 (a datetime not null, primary key(a)) engine='InnoDB'
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3),
|
partition quarter1 values in (1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
@ -1316,7 +1316,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` datetime NOT NULL,
|
`a` datetime NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = InnoDB) */
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = InnoDB, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = InnoDB, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = InnoDB, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = InnoDB) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t4 values (adddate(19700101000000,interval 12-1 month));
|
insert into t4 values (adddate(19700101000000,interval 12-1 month));
|
||||||
insert into t4 values (adddate(19700101000000,interval 11-1 month));
|
insert into t4 values (adddate(19700101000000,interval 11-1 month));
|
||||||
|
@ -186,7 +186,7 @@ a
|
|||||||
1971-01-01 00:00:59
|
1971-01-01 00:00:59
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a timestamp not null, primary key(a)) engine='MyISAM'
|
create table t3 (a timestamp not null, primary key(a)) engine='MyISAM'
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -198,7 +198,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = MyISAM) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t3 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
insert into t3 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
||||||
insert into t3 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
insert into t3 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
||||||
@ -233,7 +233,7 @@ a
|
|||||||
1970-12-01 00:00:00
|
1970-12-01 00:00:00
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a timestamp not null, primary key(a)) engine='MyISAM'
|
create table t4 (a timestamp not null, primary key(a)) engine='MyISAM'
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (0,1,2,3),
|
partition quarter1 values in (0,1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
@ -245,7 +245,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (0,1,2,3) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (0,1,2,3) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = MyISAM) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t4 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
insert into t4 values (date_add('1970-01-01 00:00:00',interval 12-1 month));
|
||||||
insert into t4 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
insert into t4 values (date_add('1970-01-01 00:00:00',interval 11-1 month));
|
||||||
@ -517,7 +517,7 @@ a
|
|||||||
1970-03-28
|
1970-03-28
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a date not null, primary key(a)) engine='MyISAM'
|
create table t3 (a date not null, primary key(a)) engine='MyISAM'
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -529,7 +529,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` date NOT NULL,
|
`a` date NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = MyISAM) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t3 values (adddate(19700101,interval 12-1 month));
|
insert into t3 values (adddate(19700101,interval 12-1 month));
|
||||||
insert into t3 values (adddate(19700101,interval 11-1 month));
|
insert into t3 values (adddate(19700101,interval 11-1 month));
|
||||||
@ -562,7 +562,7 @@ a
|
|||||||
1970-12-01
|
1970-12-01
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a date not null, primary key(a)) engine='MyISAM'
|
create table t4 (a date not null, primary key(a)) engine='MyISAM'
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3),
|
partition quarter1 values in (1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
@ -574,7 +574,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` date NOT NULL,
|
`a` date NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = MyISAM) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t4 values (adddate(19700101,interval 12-1 month));
|
insert into t4 values (adddate(19700101,interval 12-1 month));
|
||||||
insert into t4 values (adddate(19700101,interval 11-1 month));
|
insert into t4 values (adddate(19700101,interval 11-1 month));
|
||||||
@ -794,7 +794,7 @@ a
|
|||||||
00:01:59
|
00:01:59
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a time not null, primary key(a)) engine='MyISAM'
|
create table t3 (a time not null, primary key(a)) engine='MyISAM'
|
||||||
partition by range (cast(second(a) as unsigned)) subpartition by key (a)
|
partition by range (second(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (16),
|
partition quarter1 values less than (16),
|
||||||
partition quarter2 values less than (31),
|
partition quarter2 values less than (31),
|
||||||
@ -806,7 +806,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` time NOT NULL,
|
`a` time NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(second(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (16) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (31) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (46) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (61) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (second(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (16) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (31) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (46) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (61) ENGINE = MyISAM) */
|
||||||
59 inserts;
|
59 inserts;
|
||||||
insert into t3 values (100000+59);
|
insert into t3 values (100000+59);
|
||||||
insert into t3 values (100000+58);
|
insert into t3 values (100000+58);
|
||||||
@ -933,7 +933,7 @@ a
|
|||||||
10:00:59
|
10:00:59
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a time not null, primary key(a)) engine='MyISAM'
|
create table t4 (a time not null, primary key(a)) engine='MyISAM'
|
||||||
partition by list (cast(second(a) as unsigned)) subpartition by key (a)
|
partition by list (second(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15),
|
partition quarter1 values in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15),
|
||||||
partition quarter2 values in (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30),
|
partition quarter2 values in (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30),
|
||||||
@ -945,7 +945,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` time NOT NULL,
|
`a` time NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(second(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (31,32,33,34,35,36,37,38,39,40,41,42,43,44,45) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (46,47,48,49,50,51,52,53,54,55,56,57,58,59,60) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (second(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (16,17,18,19,20,21,22,23,24,25,26,27,28,29,30) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (31,32,33,34,35,36,37,38,39,40,41,42,43,44,45) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (46,47,48,49,50,51,52,53,54,55,56,57,58,59,60) ENGINE = MyISAM) */
|
||||||
59 inserts;
|
59 inserts;
|
||||||
insert into t4 values (100000+59);
|
insert into t4 values (100000+59);
|
||||||
insert into t4 values (100000+58);
|
insert into t4 values (100000+58);
|
||||||
@ -1259,7 +1259,7 @@ a
|
|||||||
1970-01-01 00:00:59
|
1970-01-01 00:00:59
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a datetime not null, primary key(a)) engine='MyISAM'
|
create table t3 (a datetime not null, primary key(a)) engine='MyISAM'
|
||||||
partition by range (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by range (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values less than (4),
|
partition quarter1 values less than (4),
|
||||||
partition quarter2 values less than (7),
|
partition quarter2 values less than (7),
|
||||||
@ -1271,7 +1271,7 @@ Table Create Table
|
|||||||
t3 CREATE TABLE `t3` (
|
t3 CREATE TABLE `t3` (
|
||||||
`a` datetime NOT NULL,
|
`a` datetime NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES LESS THAN (4) ENGINE = MyISAM, PARTITION quarter2 VALUES LESS THAN (7) ENGINE = MyISAM, PARTITION quarter3 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION quarter4 VALUES LESS THAN (13) ENGINE = MyISAM) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t3 values (adddate(19700101000000,interval 12-1 month));
|
insert into t3 values (adddate(19700101000000,interval 12-1 month));
|
||||||
insert into t3 values (adddate(19700101000000,interval 11-1 month));
|
insert into t3 values (adddate(19700101000000,interval 11-1 month));
|
||||||
@ -1304,7 +1304,7 @@ a
|
|||||||
1970-12-01 00:00:00
|
1970-12-01 00:00:00
|
||||||
drop table t3;
|
drop table t3;
|
||||||
create table t4 (a datetime not null, primary key(a)) engine='MyISAM'
|
create table t4 (a datetime not null, primary key(a)) engine='MyISAM'
|
||||||
partition by list (cast(month(a) as unsigned)) subpartition by key (a)
|
partition by list (month(a)) subpartition by key (a)
|
||||||
subpartitions 3 (
|
subpartitions 3 (
|
||||||
partition quarter1 values in (1,2,3),
|
partition quarter1 values in (1,2,3),
|
||||||
partition quarter2 values in (4,5,6),
|
partition quarter2 values in (4,5,6),
|
||||||
@ -1316,7 +1316,7 @@ Table Create Table
|
|||||||
t4 CREATE TABLE `t4` (
|
t4 CREATE TABLE `t4` (
|
||||||
`a` datetime NOT NULL,
|
`a` datetime NOT NULL,
|
||||||
PRIMARY KEY (`a`)
|
PRIMARY KEY (`a`)
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(month(a) as unsigned)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = MyISAM) */
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (month(a)) SUBPARTITION BY KEY (a) SUBPARTITIONS 3 (PARTITION quarter1 VALUES IN (1,2,3) ENGINE = MyISAM, PARTITION quarter2 VALUES IN (4,5,6) ENGINE = MyISAM, PARTITION quarter3 VALUES IN (7,8,9) ENGINE = MyISAM, PARTITION quarter4 VALUES IN (10,11,12) ENGINE = MyISAM) */
|
||||||
12 inserts;
|
12 inserts;
|
||||||
insert into t4 values (adddate(19700101000000,interval 12-1 month));
|
insert into t4 values (adddate(19700101000000,interval 12-1 month));
|
||||||
insert into t4 values (adddate(19700101000000,interval 11-1 month));
|
insert into t4 values (adddate(19700101000000,interval 11-1 month));
|
||||||
|
@ -87,95 +87,3 @@ select count(*) from t2;
|
|||||||
count(*)
|
count(*)
|
||||||
3072
|
3072
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a decimal(18,9) not null, primary key(a)) engine='InnoDB'
|
|
||||||
partition by range (cast(floor(a) as signed)) subpartition by key (a) subpartitions 2 (
|
|
||||||
partition pa2 values less than (2),
|
|
||||||
partition pa4 values less than (4),
|
|
||||||
partition pa6 values less than (6),
|
|
||||||
partition pa8 values less than (8),
|
|
||||||
partition pa10 values less than (10)
|
|
||||||
);
|
|
||||||
show create table t3;
|
|
||||||
Table Create Table
|
|
||||||
t3 CREATE TABLE `t3` (
|
|
||||||
`a` decimal(18,9) NOT NULL,
|
|
||||||
PRIMARY KEY (`a`)
|
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(floor(a) as signed)) SUBPARTITION BY KEY (a) SUBPARTITIONS 2 (PARTITION pa2 VALUES LESS THAN (2) ENGINE = InnoDB, PARTITION pa4 VALUES LESS THAN (4) ENGINE = InnoDB, PARTITION pa6 VALUES LESS THAN (6) ENGINE = InnoDB, PARTITION pa8 VALUES LESS THAN (8) ENGINE = InnoDB, PARTITION pa10 VALUES LESS THAN (10) ENGINE = InnoDB) */
|
|
||||||
9*3 inserts;
|
|
||||||
insert into t3 values (9);
|
|
||||||
insert into t3 values (9+0.333333333);
|
|
||||||
insert into t3 values (9+0.755555555);
|
|
||||||
insert into t3 values (8);
|
|
||||||
insert into t3 values (8+0.333333333);
|
|
||||||
insert into t3 values (8+0.755555555);
|
|
||||||
insert into t3 values (7);
|
|
||||||
insert into t3 values (7+0.333333333);
|
|
||||||
insert into t3 values (7+0.755555555);
|
|
||||||
insert into t3 values (6);
|
|
||||||
insert into t3 values (6+0.333333333);
|
|
||||||
insert into t3 values (6+0.755555555);
|
|
||||||
insert into t3 values (5);
|
|
||||||
insert into t3 values (5+0.333333333);
|
|
||||||
insert into t3 values (5+0.755555555);
|
|
||||||
insert into t3 values (4);
|
|
||||||
insert into t3 values (4+0.333333333);
|
|
||||||
insert into t3 values (4+0.755555555);
|
|
||||||
insert into t3 values (3);
|
|
||||||
insert into t3 values (3+0.333333333);
|
|
||||||
insert into t3 values (3+0.755555555);
|
|
||||||
insert into t3 values (2);
|
|
||||||
insert into t3 values (2+0.333333333);
|
|
||||||
insert into t3 values (2+0.755555555);
|
|
||||||
insert into t3 values (1);
|
|
||||||
insert into t3 values (1+0.333333333);
|
|
||||||
insert into t3 values (1+0.755555555);
|
|
||||||
select count(*) from t3;
|
|
||||||
count(*)
|
|
||||||
27
|
|
||||||
drop table t3;
|
|
||||||
create table t4 (a decimal(18,9) not null, primary key(a)) engine='InnoDB'
|
|
||||||
partition by list (cast(floor(a) as signed)) subpartition by key (a) subpartitions 2 (
|
|
||||||
partition pa2 values in (1,2),
|
|
||||||
partition pa4 values in (3,4),
|
|
||||||
partition pa6 values in (5,6),
|
|
||||||
partition pa8 values in (7,8),
|
|
||||||
partition pa10 values in (9,10)
|
|
||||||
);
|
|
||||||
show create table t4;
|
|
||||||
Table Create Table
|
|
||||||
t4 CREATE TABLE `t4` (
|
|
||||||
`a` decimal(18,9) NOT NULL,
|
|
||||||
PRIMARY KEY (`a`)
|
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(floor(a) as signed)) SUBPARTITION BY KEY (a) SUBPARTITIONS 2 (PARTITION pa2 VALUES IN (1,2) ENGINE = InnoDB, PARTITION pa4 VALUES IN (3,4) ENGINE = InnoDB, PARTITION pa6 VALUES IN (5,6) ENGINE = InnoDB, PARTITION pa8 VALUES IN (7,8) ENGINE = InnoDB, PARTITION pa10 VALUES IN (9,10) ENGINE = InnoDB) */
|
|
||||||
9*3 inserts;
|
|
||||||
insert into t4 values (9);
|
|
||||||
insert into t4 values (9+0.333333333);
|
|
||||||
insert into t4 values (9+0.755555555);
|
|
||||||
insert into t4 values (8);
|
|
||||||
insert into t4 values (8+0.333333333);
|
|
||||||
insert into t4 values (8+0.755555555);
|
|
||||||
insert into t4 values (7);
|
|
||||||
insert into t4 values (7+0.333333333);
|
|
||||||
insert into t4 values (7+0.755555555);
|
|
||||||
insert into t4 values (6);
|
|
||||||
insert into t4 values (6+0.333333333);
|
|
||||||
insert into t4 values (6+0.755555555);
|
|
||||||
insert into t4 values (5);
|
|
||||||
insert into t4 values (5+0.333333333);
|
|
||||||
insert into t4 values (5+0.755555555);
|
|
||||||
insert into t4 values (4);
|
|
||||||
insert into t4 values (4+0.333333333);
|
|
||||||
insert into t4 values (4+0.755555555);
|
|
||||||
insert into t4 values (3);
|
|
||||||
insert into t4 values (3+0.333333333);
|
|
||||||
insert into t4 values (3+0.755555555);
|
|
||||||
insert into t4 values (2);
|
|
||||||
insert into t4 values (2+0.333333333);
|
|
||||||
insert into t4 values (2+0.755555555);
|
|
||||||
insert into t4 values (1);
|
|
||||||
insert into t4 values (1+0.333333333);
|
|
||||||
insert into t4 values (1+0.755555555);
|
|
||||||
select count(*) from t4;
|
|
||||||
count(*)
|
|
||||||
27
|
|
||||||
drop table t4;
|
|
||||||
|
@ -87,95 +87,3 @@ select count(*) from t2;
|
|||||||
count(*)
|
count(*)
|
||||||
196605
|
196605
|
||||||
drop table t2;
|
drop table t2;
|
||||||
create table t3 (a decimal(18,9) not null, primary key(a)) engine='MYISAM'
|
|
||||||
partition by range (cast(floor(a) as signed)) subpartition by key (a) subpartitions 2 (
|
|
||||||
partition pa2 values less than (2),
|
|
||||||
partition pa4 values less than (4),
|
|
||||||
partition pa6 values less than (6),
|
|
||||||
partition pa8 values less than (8),
|
|
||||||
partition pa10 values less than (10)
|
|
||||||
);
|
|
||||||
show create table t3;
|
|
||||||
Table Create Table
|
|
||||||
t3 CREATE TABLE `t3` (
|
|
||||||
`a` decimal(18,9) NOT NULL,
|
|
||||||
PRIMARY KEY (`a`)
|
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (cast(floor(a) as signed)) SUBPARTITION BY KEY (a) SUBPARTITIONS 2 (PARTITION pa2 VALUES LESS THAN (2) ENGINE = MyISAM, PARTITION pa4 VALUES LESS THAN (4) ENGINE = MyISAM, PARTITION pa6 VALUES LESS THAN (6) ENGINE = MyISAM, PARTITION pa8 VALUES LESS THAN (8) ENGINE = MyISAM, PARTITION pa10 VALUES LESS THAN (10) ENGINE = MyISAM) */
|
|
||||||
9*3 inserts;
|
|
||||||
insert into t3 values (9);
|
|
||||||
insert into t3 values (9+0.333333333);
|
|
||||||
insert into t3 values (9+0.755555555);
|
|
||||||
insert into t3 values (8);
|
|
||||||
insert into t3 values (8+0.333333333);
|
|
||||||
insert into t3 values (8+0.755555555);
|
|
||||||
insert into t3 values (7);
|
|
||||||
insert into t3 values (7+0.333333333);
|
|
||||||
insert into t3 values (7+0.755555555);
|
|
||||||
insert into t3 values (6);
|
|
||||||
insert into t3 values (6+0.333333333);
|
|
||||||
insert into t3 values (6+0.755555555);
|
|
||||||
insert into t3 values (5);
|
|
||||||
insert into t3 values (5+0.333333333);
|
|
||||||
insert into t3 values (5+0.755555555);
|
|
||||||
insert into t3 values (4);
|
|
||||||
insert into t3 values (4+0.333333333);
|
|
||||||
insert into t3 values (4+0.755555555);
|
|
||||||
insert into t3 values (3);
|
|
||||||
insert into t3 values (3+0.333333333);
|
|
||||||
insert into t3 values (3+0.755555555);
|
|
||||||
insert into t3 values (2);
|
|
||||||
insert into t3 values (2+0.333333333);
|
|
||||||
insert into t3 values (2+0.755555555);
|
|
||||||
insert into t3 values (1);
|
|
||||||
insert into t3 values (1+0.333333333);
|
|
||||||
insert into t3 values (1+0.755555555);
|
|
||||||
select count(*) from t3;
|
|
||||||
count(*)
|
|
||||||
27
|
|
||||||
drop table t3;
|
|
||||||
create table t4 (a decimal(18,9) not null, primary key(a)) engine='MYISAM'
|
|
||||||
partition by list (cast(floor(a) as signed)) subpartition by key (a) subpartitions 2 (
|
|
||||||
partition pa2 values in (1,2),
|
|
||||||
partition pa4 values in (3,4),
|
|
||||||
partition pa6 values in (5,6),
|
|
||||||
partition pa8 values in (7,8),
|
|
||||||
partition pa10 values in (9,10)
|
|
||||||
);
|
|
||||||
show create table t4;
|
|
||||||
Table Create Table
|
|
||||||
t4 CREATE TABLE `t4` (
|
|
||||||
`a` decimal(18,9) NOT NULL,
|
|
||||||
PRIMARY KEY (`a`)
|
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY LIST (cast(floor(a) as signed)) SUBPARTITION BY KEY (a) SUBPARTITIONS 2 (PARTITION pa2 VALUES IN (1,2) ENGINE = MyISAM, PARTITION pa4 VALUES IN (3,4) ENGINE = MyISAM, PARTITION pa6 VALUES IN (5,6) ENGINE = MyISAM, PARTITION pa8 VALUES IN (7,8) ENGINE = MyISAM, PARTITION pa10 VALUES IN (9,10) ENGINE = MyISAM) */
|
|
||||||
9*3 inserts;
|
|
||||||
insert into t4 values (9);
|
|
||||||
insert into t4 values (9+0.333333333);
|
|
||||||
insert into t4 values (9+0.755555555);
|
|
||||||
insert into t4 values (8);
|
|
||||||
insert into t4 values (8+0.333333333);
|
|
||||||
insert into t4 values (8+0.755555555);
|
|
||||||
insert into t4 values (7);
|
|
||||||
insert into t4 values (7+0.333333333);
|
|
||||||
insert into t4 values (7+0.755555555);
|
|
||||||
insert into t4 values (6);
|
|
||||||
insert into t4 values (6+0.333333333);
|
|
||||||
insert into t4 values (6+0.755555555);
|
|
||||||
insert into t4 values (5);
|
|
||||||
insert into t4 values (5+0.333333333);
|
|
||||||
insert into t4 values (5+0.755555555);
|
|
||||||
insert into t4 values (4);
|
|
||||||
insert into t4 values (4+0.333333333);
|
|
||||||
insert into t4 values (4+0.755555555);
|
|
||||||
insert into t4 values (3);
|
|
||||||
insert into t4 values (3+0.333333333);
|
|
||||||
insert into t4 values (3+0.755555555);
|
|
||||||
insert into t4 values (2);
|
|
||||||
insert into t4 values (2+0.333333333);
|
|
||||||
insert into t4 values (2+0.755555555);
|
|
||||||
insert into t4 values (1);
|
|
||||||
insert into t4 values (1+0.333333333);
|
|
||||||
insert into t4 values (1+0.755555555);
|
|
||||||
select count(*) from t4;
|
|
||||||
count(*)
|
|
||||||
27
|
|
||||||
drop table t4;
|
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user