Changeset 879 for trunk/includes/Global.php
- Timestamp:
- Apr 7, 2020, 9:53:00 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/includes/Global.php
r874 r879 588 588 589 589 $where = '(`Language` = '.$Config['OriginalLanguage'].') '; 590 if ($mode == 1) $where .= ' AND EXISTS(SELECT 1 FROM `'.$Table. 590 if ($mode == 1) 591 { 592 $where .= ' AND EXISTS(SELECT 1 FROM `'.$Table. 591 593 '` AS `Sub` WHERE (`Sub`.`Language` <> '.$Config['OriginalLanguage']. 592 594 ') AND (`Sub`.`Entry` = `O`.`Entry`))'; 593 if ($mode == 2) $where .= ' AND NOT EXISTS(SELECT 1 FROM `'.$Table. 595 } 596 if ($mode == 2) 597 { 598 $where .= ' AND NOT EXISTS(SELECT 1 FROM `'.$Table. 594 599 '` AS `Sub` WHERE (`Sub`.`Language` <> '.$Config['OriginalLanguage']. 595 600 ') AND (`Sub`.`Entry` = `O`.`Entry`))'; 601 } 596 602 $where .= ' AND ('; 597 if (array_search('the', $ArrStr)) $where .= '(`O`.`'.$Column.'` LIKE "The %") OR '; 603 if (array_search('the', $ArrStr)) 604 { 605 $where .= '(`O`.`'.$Column.'` LIKE "The %") OR '; 606 } 598 607 599 608 $SqlOK = false; … … 618 627 //$sql.$where.$groupby.$orderby 619 628 // $buff[] = array($Line['ID'], GetIDbyName($Table), $Line['Orig'], $Line['Tran']); 620 if ($sqlall <> '') { $sqlall .= ' UNION ALL ( '.$sql.$where.$groupby.' )';} 621 else {$sqlall .= ' ( '.$sql.$where.$groupby.' )'; } 629 if ($sqlall <> '') 630 { 631 $sqlall .= ' UNION ALL ( '.$sql.$where.$groupby.' )'; 632 } else { 633 $sqlall .= ' ( '.$sql.$where.$groupby.' )'; 634 } 622 635 } 623 636 }
Note:
See TracChangeset
for help on using the changeset viewer.