mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-19 00:28:47 +02:00
(retrofit from trunk) Optimization: do not load all columns when checking if a CI is part of the "context" of a given ticket.
SVN:2.2.0[3930]
This commit is contained in:
@@ -250,6 +250,7 @@ class RelationGraph extends SimpleGraph
|
||||
$aAliasNames = array_keys($aAliases);
|
||||
$sRootCauseAlias = $aAliasNames[1]; // 1st column (=0) = object, second column = root cause
|
||||
$oSet = new DBObjectSet($aContextQuery['search'], array(), array('id' => $oObj->GetKey()));
|
||||
$oSet->OptimizeColumnLoad(array($aAliasNames[0] => array(), $aAliasNames[1] => array())); // Do not load any column... better do a reload than many joins
|
||||
while($aRow = $oSet->FetchAssoc())
|
||||
{
|
||||
if (!is_null($aRow[$sRootCauseAlias]))
|
||||
|
||||
Reference in New Issue
Block a user