diff options
author | cps@outpost.site <> | 2006-01-19 05:56:06 +0300 |
---|---|---|
committer | cps@outpost.site <> | 2006-01-19 05:56:06 +0300 |
commit | ce2eb6d8cb1dfb99002d006e0eeec3e3ef84fb80 (patch) | |
tree | 7c4ed26ee5f9b700099b772510ed9aa085bad459 /mysql-test/t/csv.test | |
parent | b6ed13a36ba1657b5abf26191e6d5cd88ee13130 (diff) | |
download | mariadb-git-ce2eb6d8cb1dfb99002d006e0eeec3e3ef84fb80.tar.gz |
WL1019: complete patch. Reapplied patch to the clean
tree to get rid of multiple typos in CS comments and
unify the patch.
Diffstat (limited to 'mysql-test/t/csv.test')
-rw-r--r-- | mysql-test/t/csv.test | 36 |
1 files changed, 35 insertions, 1 deletions
diff --git a/mysql-test/t/csv.test b/mysql-test/t/csv.test index a028f6ced6d..6f0f42f109c 100644 --- a/mysql-test/t/csv.test +++ b/mysql-test/t/csv.test @@ -2,7 +2,7 @@ # Test for the CSV engine # --- source include/have_csv.inc +--source include/have_csv.inc # # Simple select test @@ -1354,6 +1354,40 @@ DROP TABLE bug14672; # End of 4.1 tests # +# Test CONCURRENT INSERT (5.1) +# + +CREATE TABLE test_concurrent_insert ( val integer ) ENGINE = CSV; + +connect (con1,localhost,root,,); +connect (con2,localhost,root,,); + +connection con1; +# obtain TL_READ lock on the table +LOCK TABLES test_concurrent_insert READ LOCAL; + +connection con2; +# should pass despite of the lock +INSERT INTO test_concurrent_insert VALUES (1); +SELECT * FROM test_concurrent_insert; + +connection con1; +# first connection should not notice the changes +SELECT * FROM test_concurrent_insert; + +UNLOCK TABLES; + +# Now check that we see our own changes + +LOCK TABLES test_concurrent_insert WRITE; +INSERT INTO test_concurrent_insert VALUES (2); +SELECT * FROM test_concurrent_insert; +UNLOCK TABLES; + +# cleanup +DROP TABLE test_concurrent_insert; + +# # BUG#13406 - incorrect amount of "records deleted" # |