CREATE TABLE t2 (a varchar(32), b int(11), c float, d double, UNIQUE KEY a (a,b,c)) transactional=0 row_format=dynamic; CREATE TABLE t1 (a varchar(32), b char(3), UNIQUE KEY a (a,b), KEY b (b)) transactional=0 row_format=dynamic; INSERT INTO t1 (a, b) VALUES ( 'ppfcz1', 'DE'), ( 'ppfcz1', 'FR'); INSERT INTO t2 (a, b, c, d) VALUES ( 'ppfcz1', 14, 5, 48.5), ( 'ppfcz1', 14, 6, 52.5); # gives: 1030: Got error 176 from storage engine SELECT t1.a,t2.a,t2.c,t2.d FROM t1, t2 WHERE t2.b=14 AND t2.a=t1.a AND 5.1