Mantis Bugtracker          
testlink.org

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0008490TestLinkReq Overviewpublic2018-11-27 06:102018-12-17 13:07
Reportercartman 
Assigned Tofman 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSRed Hat Enterprise Linux ServerOS Version6.7
Product Version1.9.18 (2018 Q3) 
Fixed in Version1.9.19 (2019 Q1) 
Summary0008490: in TestLink 1.9.18 database error occurs when overviewing requirements
DescriptionAfter upgrading from 1.9.17 to 1.9.18 using PostgreSQL scripts a database error occurs when viewing requirements
==============================================================================
 DB Access Error - debug_print_backtrace() OUTPUT START
 ATTENTION: Enabling more debug info will produce path disclosure weakness (CWE-200)
            Having this additional Information could be useful for reporting
            issue to development TEAM.
 ==============================================================================
#0 database->exec_query(/* Class:requirement_mgr - Method: getLatestReqVersionCoverageCounterSet */ SELECT RCOV.req_id, COUNT(0) AS qty FROM req_coverage RCOV JOIN latest_req_version_id LRQV ON LRQV.req_version_id = RCOV.req_version_id WHERE LRQV.req_version_id IN (195,192,197,201,1722,205,142,140,203,1724,157,184,186,159,1730,1728,1720,1726,207,1714,1732,138,1716,136,1718,1712,8203,10888,10896,10912,10914,11311,10711,10715,11130,11322,11464,10709,11316,11320,11325,11527,13129,21912,11697,13047,12987,11529,13131,13275,13273,13279,199,13281,13784,10890,16413,10707,16461,20673,21628,10703,10866,11128,11166,21871,15989,21211,21873,21880,21868,21995,22067) AND is_active = 1 GROUP BY req_id , -1) called at [/app/testlink/lib/functions/database.class.php:647]
#1 database->fetchRowsIntoMap(/* Class:requirement_mgr - Method: getLatestReqVersionCoverageCounterSet */ SELECT RCOV.req_id, COUNT(0) AS qty FROM req_coverage RCOV JOIN latest_req_version_id LRQV ON LRQV.req_version_id = RCOV.req_version_id WHERE LRQV.req_version_id IN (195,192,197,201,1722,205,142,140,203,1724,157,184,186,159,1730,1728,1720,1726,207,1714,1732,138,1716,136,1718,1712,8203,10888,10896,10912,10914,11311,10711,10715,11130,11322,11464,10709,11316,11320,11325,11527,13129,21912,11697,13047,12987,11529,13131,13275,13273,13279,199,13281,13784,10890,16413,10707,16461,20673,21628,10703,10866,11128,11166,21871,15989,21211,21873,21880,21868,21995,22067) AND is_active = 1 GROUP BY req_id , req_id) called at [/app/testlink/lib/functions/requirement_mgr.class.php:4781]
0000002 requirement_mgr->getLatestReqVersionCoverageCounterSet(Array ([0] => 195,[1] => 192,[2] => 197,[3] => 201,[4] => 1722,[5] => 205,[6] => 142,[7] => 140,[8] => 203,[9] => 1724,[10] => 157,[11] => 184,[12] => 186,[13] => 159,[14] => 1730,[15] => 1728,[16] => 1720,[17] => 1726,[18] => 207,[19] => 1714,[20] => 1732,[21] => 138,[22] => 1716,[23] => 136,[24] => 1718,[25] => 1712,[26] => 8203,[27] => 10888,[28] => 10896,[29] => 10912,[30] => 10914,[31] => 11311,[32] => 10711,[33] => 10715,[34] => 11130,[35] => 11322,[36] => 11464,[37] => 10709,[38] => 11316,[39] => 11320,[40] => 11325,[41] => 11527,[42] => 13129,[43] => 21912,[44] => 11697,[45] => 13047,[46] => 12987,[47] => 11529,[48] => 13131,[49] => 13275,[50] => 13273,[51] => 13279,[52] => 199,[53] => 13281,[54] => 13784,[55] => 10890,[56] => 16413,[57] => 10707,[58] => 16461,[59] => 20673,[60] => 21628,[61] => 10703,[62] => 10866,[63] => 11128,[64] => 11166,[65] => 21871,[66] => 15989,[67] => 21211,[68] => 21873,[69] => 21880,[70] => 21868,[71] => 21995,[72] => 22067)) called at [/app/testlink/lib/requirements/reqOverview.php:77]
Steps To Reproduce1. Update database using latest package scripts from https://github.com/TestLinkOpenSourceTRMS/testlink-code/archive/testlink_1_9.zip [^]
/app/testlink/install/sql/alter_tables/1.9.17/postgres/DB.1.9.17/step1/db_schema_update.sql
/app/testlink/install/sql/alter_tables/1.9.17/postgres/DB.1.9.17/step1/db_udf_update.sql
/app/testlink/install/sql/alter_tables/1.9.18/postgres/DB.1.9.18/step1/db_schema_update.sql
/app/testlink/install/sql/alter_tables/1.9.18/postgres/DB.1.9.18/stepZ/z_final_step.sql
2. Update TestLink application to 1.9.18 (Stable) using https://sourceforge.net/projects/testlink/files/TestLink%201.9/TestLink%201.9.18/testlink-1.9.18.tar.gz/download [^]
3. Enter the TestLink and follow the Requirement Overview link
Additional Informationin the database log, the relation "latest_req_version_id" does not exist
TagsNo tags attached.
Database (MySQL,Postgres,etc) Postgres
BrowserChrome 62.0.3202.89
PHP Version7.0.31
TestCaseID
QA Team - Task Workflow StatusREADY FOR TESTING
Attached Files

- Relationships
child of 0008397closedfman Availables hot-fixes for 1.9.18 & How To get full fixed package from GitHub 

-  Notes
(0028321)
fman (administrator)
2018-12-16 14:43

missing alias in GROUP BY is not liked by Postgres, but MySQL has no issue
(0028322)
fman (administrator)
2018-12-16 14:45

https://github.com/TestLinkOpenSourceTRMS/testlink-code/commit/97d633604fe93a36c026ec6f724ffdf674111c1b [^]
(0028324)
cartman (reporter)
2018-12-17 08:21

after installing the updated file requirement_mgr.class.php got the db error relation "latest_req_version_id" does not exist

analysis of the update scripts for postgres version 1.9.18 showed that the file /testlink/install/sql/alter_tables/1.9.18/postgres
is missing the view 'latest_req_version_id' which is present in the script full installation version
testlink/install/sql/postgres / testlink_create_tables.sql

DATABASE

ERROR ON exec_query() - database.class.php
-1 - ERROR: relationship 'latest_req_version_id' does not exist LINE 1: ...id,
COUNT(0) AS qty FROM req_coverage RCOV JOIN latest_req... ^ - /* Class:requirement_mgr - Method: getLatestReqVersionCoverageCounterSet */ SELECT RCOV.req_id,
COUNT(0) AS qty FROM req_coverage RCOV JOIN latest_req_version_id LRQV ON LRQV.req_version_id = RCOV.req_version_id WHERE LRQV.req_version_id
IN (195,192,197,201,1722,205,142,140,203,1724,157,184,186,159,1730,1728,1720,1726,207,1714,1732,138,1716,136,1718,1712,8203,10888,10896,10912,10914,11311,
10711,10715,11130,11322,11464,10709,11316,11320,11325,11527,13129,21912,11697,13047,12987,11529,13131,13275,13273,13279,199,13281,13784,10890,16413,10707,
16461,20673,21628,10703,10866,11128,11166,21871,15989,21211,21873,21880,21868,21995,22067) AND is_active = 1
GROUP BY req_id
THE MESSAGE : /* Class:requirement_mgr - Method: getLatestReqVersionCoverageCounterSet */ SELECT RCOV.req_id,
COUNT(0) AS qty FROM req_coverage RCOV JOIN latest_req_version_id LRQV ON LRQV.req_version_id = RCOV.req_version_id WHERE LRQV.req_version_id IN
(195,192,197,201,1722,205,142,140,203,1724,157,184,186,159,1730,1728,1720,1726,207,1714,1732,138,1716,136,1718,1712,8203,10888,10896,10912,10914,11311,
10711,10715,11130,11322,11464,10709,11316,11320,11325,11527,13129,21912,11697,13047,12987,11529,13131,13275,13273,13279,199,13281,13784,10890,16413,10707,
16461,20673,21628,10703,10866,11128,11166,21871,15989,21211,21873,21880,21868,21995,22067) AND is_active = 1
GROUP BY req_id Query failed: errorcode[-1] errormsg:ERROR: relationship 'latest_req_version_id' does not exist LINE 1: ...id, COUNT(0) AS
qty FROM req_coverage RCOV JOIN latest_req... ^

- Issue History
Date Modified Username Field Change
2018-11-27 06:10 cartman New Issue
2018-12-16 14:43 fman Note Added: 0028321
2018-12-16 14:45 fman Relationship added child of 0008397
2018-12-16 14:45 fman QA Team - Task Workflow Status => READY FOR TESTING
2018-12-16 14:45 fman Note Added: 0028322
2018-12-16 14:45 fman Status new => resolved
2018-12-16 14:45 fman Fixed in Version => 1.9.19 (2019 Q1)
2018-12-16 14:45 fman Resolution open => fixed
2018-12-16 14:45 fman Assigned To => fman
2018-12-17 08:21 cartman Note Added: 0028324



Copyright © 2000 - 2019 MantisBT Team
Powered by Mantis Bugtracker