源码包
596360

禅道开源版16.4升级18.3失败已解决 悬赏5积分

提问者沈先生 答案数1 阅读数557 发表时间2023-04-09 12:39:01

禅道开源版12.5升级到16.4成功。

从16.4升级到18.3时提示失败:


SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `get_monday`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `get_monday`(day date) RETURNS date
begin if date_format(day, '%w') = 0 then return subdate(day, date_format(day, '%w') - 6);
else  return subdate(day, date_format(day, '%w') -1);
end if;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `get_sunday`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `get_sunday`(day date) RETURNS date
begin
if date_format(day, '%w') = 0 then return day;
else return subdate(day, date_format(day, '%w') - 7);
end if;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_cminited`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION qc_cminited($project int, $category varchar(30)) returns int
begin
declare products int default 0;
declare objects  int default 0;
select count(*) from zt_projectproduct where project = $project into products;
select count(distinct product) from zt_object where project = $project and category = $category and type = 'taged' and product in (select product from zt_projectproduct where project = $project) into objects;
IF products = objects THEN
return 1;
ELSEIF products != objects THEN
return 0;
END IF;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_initscale`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION qc_initscale($project int, $category varchar(30), $estimateType varchar(30)) RETURNS float(10,2)
BEGIN
declare $estimate int default 0;
declare $storyEst varchar(30) default 'storyEst';
declare $requestEst varchar(30) default 'requestEst';
if($estimateType = $storyEst) THEN SELECT sum(storyEst) as estimate FROM zt_object WHERE id in(SELECT MIN(id) FROM zt_object WHERE project = $project and category = $category and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
end if;
if($estimateType = $requestEst) THEN SELECT sum(requestEst) as estimate FROM zt_object WHERE id in(SELECT MIN(id) FROM zt_object WHERE project = $project and category = $category and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
end if;
RETURN @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmplanscale`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmplanscale`($project int) RETURNS float(10,2)
BEGIN
declare programScale float (10,2) default 0;
select `scale` from zt_workestimation where project = $project into @programScale;
return @programScale;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmsrinitscale`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmsrinitscale`($project int) RETURNS float(10,2)
begin
declare scale int default 0;
declare inited int default 0;
select qc_cminited($project, 'SRS') into inited;
IF inited = 1 THEN
select qc_initscale($project, 'SRS', 'storyEst') into scale ;
return scale ;
ELSE
return 0;
END IF;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmsrrealscale`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmsrrealscale`($project int) RETURNS float(10,2)
BEGIN
declare totalEstimate float(10,2) default 0;
select CAST(sum(estimate) as DECIMAL(10,2)) as estimate from zt_story where id in (select story from zt_projectstory where project=$project) and type='story' and deleted='0' and closedReason not in ('subdivided', 'duplicate', 'willnotdo', 'cancel', 'bydesign') into totalEstimate;
return totalEstimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmurinitscale`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmurinitscale`($project int) RETURNS float(10,2)
begin
declare scale int default 0;
declare inited int default 0;
select qc_cminited($project, 'URS') into inited;
IF inited = 1 THEN
select qc_initscale($project, 'URS', 'requestEst') into scale;
return scale;
ELSE
return 0;
END IF;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmurrealscale`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmurrealscale`($project int) RETURNS float(10,2)
BEGIN
declare totalEstimate float(10,2) default 0;
select CAST(sum(estimate) as DECIMAL(10,2)) as estimate from zt_story where project=$project and type='requirement' and deleted='0' and closedReason not in ('subdivided', 'duplicate', 'willnotdo', 'cancel', 'bydesign') into totalEstimate;
return totalEstimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmallrequirementstage`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmallrequirementstage`($project int) RETURNS int(1)
BEGIN
select count(*) as products from zt_projectproduct where project = $project into @totalproduct;
select count(*) as product from (select product from zt_projectproduct where project in (select id from zt_project where project = $project and type = 'stage' and attribute = 'request' and deleted = '0') GROUP BY product) as product into @product;
if @totalproduct = @product then return 1;
end if;
RETURN 0;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdesigntplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdesigntplandays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeplanneddays($project,'design') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdesigntrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdesigntrealdays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeactualdays($project,'design') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdevelplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdevelplandays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeplanneddays($project,'dev') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdevelrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdevelrealdays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeactualdays($project,'dev') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmrequestplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmrequestplandays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeplanneddays($project,'request') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmrequestrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmrequestrealdays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeactualdays($project,'request') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmspecifiedtypeactualdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmspecifiedtypeactualdays`($project int,$attribute varchar(50)) RETURNS int(10)
BEGIN
select count(*) from zt_project where project = $project and attribute = $attribute and deleted = '0' and id not in (select parent from zt_project where project = $project and attribute = $attribute and grade = 2 group by parent) into @totalstory;
select count(*) from zt_project where project = $project and attribute = $attribute and deleted = '0' and realDuration > 0 and id not in (select parent from zt_project where project = $project and attribute = $attribute and grade = 2 group by parent) into @setstory;
select sum(realDuration) as realDuration from zt_project where project = $project and attribute = $attribute and deleted = '0' and realDuration > 0 and id not in (select parent from zt_project where project = $project and attribute = $attribute and grade = 2 group by parent) into @days;
if @totalstory != @setstory then
set @days = 0;
end if;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmspecifiedtypeplanneddays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmspecifiedtypeplanneddays`($project int,$attribute varchar(50)) RETURNS int(10)
BEGIN
select sum(planDuration) as planDuration from zt_project where project = $project and attribute = $attribute and deleted = '0' and id not in (select parent from zt_project where project = $project and attribute = $attribute and grade = 2 group by parent) into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmstageactualduration`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmstageactualduration`($product int, $attribute varchar(50)) RETURNS int(10)
BEGIN
select count(*) as totalduration from zt_project where id in (select project from zt_projectproduct where product = $product) and type = 'stage' and attribute = $attribute and deleted = '0' and id not in (select parent from zt_project where id in (select project from zt_projectproduct where product = $product) and attribute = $attribute and grade = 2 group by parent) into @totalduration;
select count(*) as setduration from zt_project where id in (select project from zt_projectproduct where product = $product) and type = 'stage' and attribute = $attribute and deleted = '0' and id not in (select parent from zt_project where id in (select project from zt_projectproduct where product = $product) and attribute = $attribute and grade = 2 group by parent) and realDuration > 0 into @setduration;
select sum(realDuration) as duration from zt_project where id in (select project from zt_projectproduct where product = $product) and type = 'stage' and attribute = $attribute and deleted = '0' and id not in (select parent from zt_project where id in (select project from zt_projectproduct where product = $product) and attribute = $attribute and grade = 2 group by parent) and realDuration > 0 into @duration;
if @totalduration != @setduration then
set @duration = 0;
end if;
return @duration;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmstageplannedduration`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmstageplannedduration`($product int, $attribute varchar(50)) RETURNS int(10)
BEGIN
select sum(planDuration) as duration from zt_project where id in (select project from zt_projectproduct where product = $product) and attribute = $attribute and deleted = '0' and id not in (select parent from zt_project where id in (select project from zt_projectproduct where product = $product) and attribute = $attribute and grade = 2 group by parent) and planDuration > 0 into @duration;
RETURN @duration;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmtestplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmtestplandays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeplanneddays($project,'qa') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmtestrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmtestrealdays`($project int) RETURNS int(10)
BEGIN
select qc_pgmspecifiedtypeactualdays($project,'qa') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prddesigntplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prddesigntplandays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageplannedduration($project, $product, 'design') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prddesigntrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prddesigntrealdays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageactualduration($project, $product, 'design') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prddevelplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prddevelplandays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageplannedduration($project, $product, 'dev') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prddevelrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prddevelrealdays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageactualduration($project, $product, 'dev') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prdrequestplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prdrequestplandays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageplannedduration($project, $product, 'request') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prdrequestrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prdrequestrealdays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageactualduration($project, $product, 'request') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prdtestplandays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prdtestplandays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageplannedduration($project, $product, 'qa') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_prdtestrealdays`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_prdtestrealdays`($project int, $product int) RETURNS int(10)
BEGIN
select qc_pgmstageactualduration($project, $product, 'qa') as days into @days;
return @days;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdesgignrealesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdesgignrealesthours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmesthoursbytype($project, 'design');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdesignrealhours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdesignrealhours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmrealhoursbytype($project, 'design');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdevelrealesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdevelrealesthours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmesthoursbytype($project, 'devel');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmdevelrealhours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmdevelrealhours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmrealhoursbytype($project, 'devel');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmrealesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmrealesthours`($project int) RETURNS float(10,2)
BEGIN
select CAST(sum(estimate) as DECIMAL(10,2)) as estimate from zt_task where project=$project and parent >= 0 and status != 'cancel' and deleted = '0' into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmesthoursbytype`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmesthoursbytype`($project int, $type char(30)) RETURNS float(10,2)
BEGIN
select CAST(sum(estimate) as DECIMAL(10,2)) as estimate from zt_task where project=$project and type = $type and parent >= 0 and status != 'cancel' and deleted = '0' into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmrealhours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmrealhours`($project int) RETURNS float(10,2)
BEGIN
select CAST(sum(consumed) as DECIMAL(10,2)) as consumed from zt_task where project=$project and parent >= 0 and status != 'cancel' and deleted = '0' into @consumed;
return @consumed;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmrealhoursbytype`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmrealhoursbytype`($project int, $type char(30)) RETURNS float(10,2)
BEGIN
select CAST(sum(consumed) as DECIMAL(10,2)) as consumed from zt_task where project=$project and type = $type and parent >= 0 and status != 'cancel' and deleted = '0' into @consumed;
return @consumed;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmrequestrealesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmrequestrealesthours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmesthoursbytype($project, 'request');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmrequestrealhours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmrequestrealhours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmrealhoursbytype($project, 'request');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmtestrealesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmtestrealesthours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmesthoursbytype($project, 'test');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmtestrealhours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmtestrealhours`($project int) RETURNS float(10,2)
BEGIN
return qc_pgmrealhoursbytype($project, 'test');
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getdevelfirstesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getdevelfirstesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(devEst) as estimate FROM zt_object WHERE id in(SELECT MIN(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getdesignfirstesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getdesignfirstesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(designEst) as estimate FROM zt_object WHERE id in(SELECT MIN(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getstoryfirstesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getstoryfirstesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(requestEst) as estimate FROM zt_object WHERE id in(SELECT MIN(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_gettestfirstesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_gettestfirstesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(testEst) as estimate FROM zt_object WHERE id in(SELECT MIN(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getfirstesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getfirstesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(taskEst) as estimate FROM zt_object WHERE id in(SELECT MIN(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getdevlastesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getdevlastesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(devEst) as estimate FROM zt_object WHERE id in(SELECT MAX(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getrequestlastesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getrequestlastesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(requestEst) as estimate FROM zt_object WHERE id in(SELECT MAX(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_gettestlastesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_gettestlastesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(testEst) as estimate FROM zt_object WHERE id in(SELECT MAX(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getdesignlastesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getdesignlastesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(designEst) as estimate FROM zt_object WHERE id in(SELECT MAX(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_getlastesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_getlastesthours`($project int) RETURNS float(10,2)
BEGIN
SELECT sum(taskEst) as estimate FROM zt_object WHERE id in(SELECT MAX(id) FROM zt_object WHERE project = $project and category = 'PP' and type = 'taged' and product in (select product from zt_projectproduct where project = $project) group by `product`) into @estimate;
return @estimate;
END</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
DROP FUNCTION IF EXISTS `qc_pgmlastesthours`</p>
SQLSTATE[HY000]: General error: 1558 Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 100108, now running 100414. Please use mysql_upgrade to fix this error<p>The sql is: 
CREATE FUNCTION `qc_pgmlastesthours`($project int) RETURNS float(10,2)
BEGIN
declare estimate float(10,2) default 0;
declare inited int default 0;
select qc_cminited($project,'PP') into inited;
IF inited = 1 THEN
select qc_getlastesthours($project) into estimate;
return estimate;
ELSE
return 0;
END IF;
END</p>

禅道版本:禅道开源版 18.3

安装包类型:源码包

操作系统:Other

客户端浏览器:其他

备注
设置备注
内容
答案列表
🍉
2023-04-10 11:05:45
这个问题像是重新升级导致的 有2个方案:
方案1 , 新建一个禅道的数据库 不要叫zentao , 比如叫 zentao2 , 把升级到16.4 的数据导入这个库, 编辑zentao/config/my.php 文件, db改为zentao2
基于这个zentao2 数据库继续升级测试看看
方案2, mysql.proc表里面 把 db = zentao的所有数据删除 , 再还原到 16.4版本重新升级看看

所有操作前都要先做好备份


联系我们
联系人
刘斌/高级客户经理
电话(微信)
17685869372
QQ号码
526288068
联系邮箱
liubin@chandao.com
返回顶部
刘斌
高级客户经理
17685869372
526288068
统一服务热线 4006-8899-23
我要提问提问有任何问题,您都可以在这里提问。 问题反馈反馈点击这里,让我们聆听您的建议与反馈。