Bug #20046 Qcache invalidate crashes when using a SP which uses a PS and a View

Submitted: 24 May 2006 13:31 Modified: 24 May 2006 16:24
Reporter: Matthew Lord Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S1 (Critical)
Version:5.0.21, 5.0.22-bk OS:Linux (Linux 2.4, 2.6 - Windows 2003)
Assigned to: CPU Architecture:Any

[24 May 2006 13:31] Matthew Lord
Description:
Crash is occuring in Query_cache::invalidate ().  A small test case below.  If query 
cache size is set to 0 then the crash does not occur.

How to repeat:
######
DROP DATABASE IF EXISTS `test`;
CREATE DATABASE `test`;
USE `test`;

DROP PROCEDURE IF EXISTS `p1`;
DELIMITER //
CREATE PROCEDURE `p1`()
BEGIN
start transaction;
SET @sqlstr="INSERT INTO t1(`c1`) SELECT `c1` FROM v1";
PREPARE stmt FROM @sqlstr;
EXECUTE stmt;
DEALLOCATE PREPARE stmt;
END//
DELIMITER ;

DROP TABLE IF EXISTS `t1`;
CREATE TABLE `t1`(`c1` int) ENGINE=MyISAM DEFAULT CHARSET=latin1;

DROP TABLE IF EXISTS `t2`;
CREATE TABLE `t2`(`c1` INT) ENGINE=MyISAM DEFAULT CHARSET=latin1;

DROP TABLE IF EXISTS `t3`;
CREATE TABLE `t3`(`c1` INT) ENGINE=MyISAM DEFAULT CHARSET=latin1;

DROP TABLE IF EXISTS `v1`;
DROP VIEW IF EXISTS `v1`;
CREATE VIEW `v1` AS select `t3`.`c1` AS `c1` FROM `t3`,`t2` WHERE `t3`.`c1` = `t2`.`c1`;

call `p1`();
########

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.050 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.