mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Merge of 5.1-main into 5.1-maria. There were no changes to storage/myisam, or mysql-test/t/*myisam*.
However there were three new tests mysql-test/suite/parts/t/partition*myisam.test, of which I make here copies for Maria.
This commit is contained in:
@ -7203,9 +7203,6 @@ static void test_field_misc()
|
||||
{
|
||||
MYSQL_STMT *stmt;
|
||||
MYSQL_RES *result;
|
||||
MYSQL_BIND my_bind[1];
|
||||
char table_type[NAME_LEN];
|
||||
ulong type_length;
|
||||
int rc;
|
||||
|
||||
myheader("test_field_misc");
|
||||
@ -7248,53 +7245,6 @@ static void test_field_misc()
|
||||
mysql_free_result(result);
|
||||
mysql_stmt_close(stmt);
|
||||
|
||||
stmt= mysql_simple_prepare(mysql, "SELECT @@table_type");
|
||||
check_stmt(stmt);
|
||||
|
||||
rc= mysql_stmt_execute(stmt);
|
||||
check_execute(stmt, rc);
|
||||
|
||||
bzero((char*) my_bind, sizeof(my_bind));
|
||||
my_bind[0].buffer_type= MYSQL_TYPE_STRING;
|
||||
my_bind[0].buffer= table_type;
|
||||
my_bind[0].length= &type_length;
|
||||
my_bind[0].buffer_length= NAME_LEN;
|
||||
|
||||
rc= mysql_stmt_bind_result(stmt, my_bind);
|
||||
check_execute(stmt, rc);
|
||||
|
||||
rc= mysql_stmt_fetch(stmt);
|
||||
check_execute(stmt, rc);
|
||||
if (!opt_silent)
|
||||
fprintf(stdout, "\n default table type: %s(%ld)", table_type, type_length);
|
||||
|
||||
rc= mysql_stmt_fetch(stmt);
|
||||
DIE_UNLESS(rc == MYSQL_NO_DATA);
|
||||
|
||||
mysql_stmt_close(stmt);
|
||||
|
||||
stmt= mysql_simple_prepare(mysql, "SELECT @@table_type");
|
||||
check_stmt(stmt);
|
||||
|
||||
result= mysql_stmt_result_metadata(stmt);
|
||||
mytest(result);
|
||||
DIE_UNLESS(mysql_stmt_field_count(stmt) == mysql_num_fields(result));
|
||||
|
||||
rc= mysql_stmt_execute(stmt);
|
||||
check_execute(stmt, rc);
|
||||
|
||||
DIE_UNLESS(1 == my_process_stmt_result(stmt));
|
||||
|
||||
verify_prepare_field(result, 0,
|
||||
"@@table_type", "", /* field and its org name */
|
||||
mysql_get_server_version(mysql) <= 50000 ?
|
||||
MYSQL_TYPE_STRING : MYSQL_TYPE_VAR_STRING,
|
||||
"", "", /* table and its org name */
|
||||
"", type_length, 0); /* db name, length */
|
||||
|
||||
mysql_free_result(result);
|
||||
mysql_stmt_close(stmt);
|
||||
|
||||
stmt= mysql_simple_prepare(mysql, "SELECT @@max_error_count");
|
||||
check_stmt(stmt);
|
||||
|
||||
@ -7311,7 +7261,8 @@ static void test_field_misc()
|
||||
"@@max_error_count", "", /* field and its org name */
|
||||
MYSQL_TYPE_LONGLONG, /* field type */
|
||||
"", "", /* table and its org name */
|
||||
"", 10, 0); /* db name, length */
|
||||
/* db name, length */
|
||||
"", MY_INT64_NUM_DECIMAL_DIGITS , 0);
|
||||
|
||||
mysql_free_result(result);
|
||||
mysql_stmt_close(stmt);
|
||||
@ -7331,7 +7282,8 @@ static void test_field_misc()
|
||||
"@@max_allowed_packet", "", /* field and its org name */
|
||||
MYSQL_TYPE_LONGLONG, /* field type */
|
||||
"", "", /* table and its org name */
|
||||
"", 10, 0); /* db name, length */
|
||||
/* db name, length */
|
||||
"", MY_INT64_NUM_DECIMAL_DIGITS, 0);
|
||||
|
||||
mysql_free_result(result);
|
||||
mysql_stmt_close(stmt);
|
||||
|
Reference in New Issue
Block a user