mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 23:42:11 +00:00
fix some sql statements to work with mysql 5.7.5 (Closes: #273)
This commit is contained in:
parent
ec2d983bb4
commit
0afbcc73d8
|
@ -308,7 +308,7 @@ class SeedDMS_Core_DatabaseAccess {
|
|||
"MAX(`tblDocumentReviewLog`.`reviewLogID`) AS `maxLogID` ".
|
||||
"FROM `tblDocumentReviewLog` ".
|
||||
"GROUP BY `tblDocumentReviewLog`.`reviewID` ".
|
||||
"ORDER BY `tblDocumentReviewLog`.`reviewLogID`";
|
||||
"ORDER BY `maxLogID`";
|
||||
break;
|
||||
default:
|
||||
$queryStr = "CREATE TEMPORARY TABLE IF NOT EXISTS `ttreviewid` (PRIMARY KEY (`reviewID`), INDEX (`maxLogID`)) ".
|
||||
|
@ -316,7 +316,7 @@ class SeedDMS_Core_DatabaseAccess {
|
|||
"MAX(`tblDocumentReviewLog`.`reviewLogID`) AS `maxLogID` ".
|
||||
"FROM `tblDocumentReviewLog` ".
|
||||
"GROUP BY `tblDocumentReviewLog`.`reviewID` ".
|
||||
"ORDER BY `tblDocumentReviewLog`.`reviewLogID`";
|
||||
"ORDER BY `maxLogID`";
|
||||
}
|
||||
if (!$this->_ttreviewid) {
|
||||
if (!$this->getResult($queryStr))
|
||||
|
@ -341,7 +341,7 @@ class SeedDMS_Core_DatabaseAccess {
|
|||
"MAX(`tblDocumentApproveLog`.`approveLogID`) AS `maxLogID` ".
|
||||
"FROM `tblDocumentApproveLog` ".
|
||||
"GROUP BY `tblDocumentApproveLog`.`approveID` ".
|
||||
"ORDER BY `tblDocumentApproveLog`.`approveLogID`";
|
||||
"ORDER BY `maxLogID`";
|
||||
break;
|
||||
default:
|
||||
$queryStr = "CREATE TEMPORARY TABLE IF NOT EXISTS `ttapproveid` (PRIMARY KEY (`approveID`), INDEX (`maxLogID`)) ".
|
||||
|
@ -349,7 +349,7 @@ class SeedDMS_Core_DatabaseAccess {
|
|||
"MAX(`tblDocumentApproveLog`.`approveLogID`) AS `maxLogID` ".
|
||||
"FROM `tblDocumentApproveLog` ".
|
||||
"GROUP BY `tblDocumentApproveLog`.`approveID` ".
|
||||
"ORDER BY `tblDocumentApproveLog`.`approveLogID`";
|
||||
"ORDER BY `maxLogID`";
|
||||
}
|
||||
if (!$this->_ttapproveid) {
|
||||
if (!$this->getResult($queryStr))
|
||||
|
@ -374,7 +374,7 @@ class SeedDMS_Core_DatabaseAccess {
|
|||
"MAX(`tblDocumentStatusLog`.`statusLogID`) AS `maxLogID` ".
|
||||
"FROM `tblDocumentStatusLog` ".
|
||||
"GROUP BY `tblDocumentStatusLog`.`statusID` ".
|
||||
"ORDER BY `tblDocumentStatusLog`.`statusLogID`";
|
||||
"ORDER BY `maxLogID`";
|
||||
break;
|
||||
default:
|
||||
$queryStr = "CREATE TEMPORARY TABLE IF NOT EXISTS `ttstatid` (PRIMARY KEY (`statusID`), INDEX (`maxLogID`)) ".
|
||||
|
@ -382,7 +382,7 @@ class SeedDMS_Core_DatabaseAccess {
|
|||
"MAX(`tblDocumentStatusLog`.`statusLogID`) AS `maxLogID` ".
|
||||
"FROM `tblDocumentStatusLog` ".
|
||||
"GROUP BY `tblDocumentStatusLog`.`statusID` ".
|
||||
"ORDER BY `tblDocumentStatusLog`.`statusLogID`";
|
||||
"ORDER BY `maxLogID`";
|
||||
}
|
||||
if (!$this->_ttstatid) {
|
||||
if (!$this->getResult($queryStr))
|
||||
|
|
Loading…
Reference in New Issue
Block a user