diff options
author | unknown <holyfoot/hf@hfmain.(none)> | 2007-12-07 09:39:31 +0400 |
---|---|---|
committer | unknown <holyfoot/hf@hfmain.(none)> | 2007-12-07 09:39:31 +0400 |
commit | 1dd429fd3e372fcbd830a33a23e36557208d63f1 (patch) | |
tree | f72d3e03e4a5ebbc3bded247c9528b590f07026c /tests | |
parent | b9d8e34925d1be4b6c1c8950217d41456a02c542 (diff) | |
parent | 05fbb233d8e500da274dbd4bcffc134b23cfca13 (diff) | |
download | mariadb-git-1dd429fd3e372fcbd830a33a23e36557208d63f1.tar.gz |
Merge mysql.com:/home/hf/work/26921/my50-26921
into mysql.com:/home/hf/work/26921/my51-26921
libmysqld/lib_sql.cc:
Auto merged
tests/mysql_client_test.c:
Auto merged
Diffstat (limited to 'tests')
-rw-r--r-- | tests/mysql_client_test.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/mysql_client_test.c b/tests/mysql_client_test.c index 08805c4bcc1..1ede4105056 100644 --- a/tests/mysql_client_test.c +++ b/tests/mysql_client_test.c @@ -15869,6 +15869,8 @@ static void test_status() Test that client gets updated value of insert_id on UPDATE that uses LAST_INSERT_ID(expr). + select_query added to test for bug + #26921 Problem in mysql_insert_id() Embedded C API function */ static void test_bug21726() { @@ -15881,6 +15883,8 @@ static void test_bug21726() const char *update_query= "UPDATE t1 SET i= LAST_INSERT_ID(i + 1)"; int rc; my_ulonglong insert_id; + const char *select_query= "SELECT * FROM t1"; + MYSQL_RES *result; DBUG_ENTER("test_bug21726"); myheader("test_bug21726"); @@ -15897,6 +15901,13 @@ static void test_bug21726() insert_id= mysql_insert_id(mysql); DIE_UNLESS(insert_id == 3); + rc= mysql_query(mysql, select_query); + myquery(rc); + insert_id= mysql_insert_id(mysql); + DIE_UNLESS(insert_id == 3); + result= mysql_store_result(mysql); + mysql_free_result(result); + DBUG_VOID_RETURN; } |