mirror of
https://github.com/MariaDB/server.git
synced 2025-07-05 10:58:16 +02:00

handler::clone() call did not work with read only tables like S3. It gave a wrong error message (out of memory instead of a permission error) and aborted the query. The issue was that the clone call had a wrong parameter to ha_open(). This now fixed. I also changed the clone call to provide the correct error message if things fails. This patch fixes an 'out of memory' error when using the S3 engine for queries that could use multiple indexes together to find the matching rows, like the following: SELECT * FROM t1 WHERE key1 = 99 OR key2 = 2
14 lines
385 B
Text
14 lines
385 B
Text
--source include/have_s3.inc
|
|
--source include/have_sequence.inc
|
|
--source include/have_innodb.inc
|
|
|
|
--echo #
|
|
--echo # SELECT using ror_merged scan fails with s3 tables
|
|
--echo #
|
|
|
|
DROP TABLE IF EXISTS t1;
|
|
CREATE TABLE t1 (a INT, b INT, KEY(a), KEY(b)) ENGINE=Aria;
|
|
INSERT INTO t1 VALUES (0,0),(0,10),(3,10);
|
|
ALTER TABLE t1 ENGINE=S3;
|
|
SELECT * FROM t1 WHERE a = 99 OR b = 2;
|
|
DROP TABLE t1;
|