Issue Bug Closed

#63782Do not fetch all columns in ReferenceIndex->generateRefIndexData

Stephan Großberndt 12/11/14, 16:27 updated 10/02/18, 11:48

Description

Currently ReferenceIndex->generateRefIndexData fetches all data from each table and selects afterwards which fields and their contents are looked at searching for relations.

public function generateRefIndexData($table, $uid) {
    if (isset($GLOBALS['TCA'][$table])) {
        // Get raw record from DB:
        $record = $GLOBALS['TYPO3_DB']->exec_SELECTgetSingleRow('*', $table, 'uid=' . (int)$uid);

If the fields are selected beforehand using the information from the TCA a lot less data is fetched. This improves the speed of building the reference index as standalone task as well as when bulk inserting many records.

Reviews 2