mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-31 05:57:34 +00:00
fix sql statement to create temp table ttrevisionid and ttreceiptid
This commit is contained in:
parent
1326f825d3
commit
0e2b8df36b
|
@ -552,7 +552,7 @@ class SeedDMS_Core_DatabaseAccess {
|
||||||
switch($this->_driver) {
|
switch($this->_driver) {
|
||||||
case 'sqlite':
|
case 'sqlite':
|
||||||
$queryStr = "CREATE TEMPORARY TABLE IF NOT EXISTS `ttreceiptid` AS ".
|
$queryStr = "CREATE TEMPORARY TABLE IF NOT EXISTS `ttreceiptid` AS ".
|
||||||
"SELECT `tblDocumentReceiptLog`.`receiptID`, ".
|
"SELECT `tblDocumentReceiptLog`.`receiptID` AS `receiptID`, ".
|
||||||
"MAX(`tblDocumentReceiptLog`.`receiptLogID`) AS `maxLogID` ".
|
"MAX(`tblDocumentReceiptLog`.`receiptLogID`) AS `maxLogID` ".
|
||||||
"FROM `tblDocumentReceiptLog` ".
|
"FROM `tblDocumentReceiptLog` ".
|
||||||
"GROUP BY `tblDocumentReceiptLog`.`receiptID` ".
|
"GROUP BY `tblDocumentReceiptLog`.`receiptID` ".
|
||||||
|
@ -593,7 +593,7 @@ class SeedDMS_Core_DatabaseAccess {
|
||||||
switch($this->_driver) {
|
switch($this->_driver) {
|
||||||
case 'sqlite':
|
case 'sqlite':
|
||||||
$queryStr = "CREATE TEMPORARY TABLE IF NOT EXISTS `ttrevisionid` AS ".
|
$queryStr = "CREATE TEMPORARY TABLE IF NOT EXISTS `ttrevisionid` AS ".
|
||||||
"SELECT `tblDocumentRevisionLog`.`revisionID`, ".
|
"SELECT `tblDocumentRevisionLog`.`revisionID` AS `revisionID`, ".
|
||||||
"MAX(`tblDocumentRevisionLog`.`revisionLogID`) AS `maxLogID` ".
|
"MAX(`tblDocumentRevisionLog`.`revisionLogID`) AS `maxLogID` ".
|
||||||
"FROM `tblDocumentRevisionLog` ".
|
"FROM `tblDocumentRevisionLog` ".
|
||||||
"GROUP BY `tblDocumentRevisionLog`.`revisionID` ".
|
"GROUP BY `tblDocumentRevisionLog`.`revisionID` ".
|
||||||
|
|
Loading…
Reference in New Issue
Block a user