Project

General

Profile

Actions

Bug #92568

closed

PopulatePageSlugs upgrade wizard migrates wrong RealURL path data entry

Added by Mathias Brodala over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Must have
Category:
Link Handling, Site Handling & Routing
Target version:
Start date:
2020-10-15
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

The PopulatePageSlugs upgrade wizard allows to migrate entries from tx_realurl_pathdata. However, due to an additional DESC sorting, the wrong entry is used in case there is more than one for a page. This can actually happen often for $reasons.

Given the following two entries in tx_realurl_pathdata:

uid ... pagepath expire
1 ... first/path 0
2 ... second/path 0

RealURL will use the first/path, but the PopulatePageSlugs upgrade wizard will use the second/path. This leads to changed URLs after the upgrade.

RealURL itself does not apply any explicit sorting:

https://github.com/dmitryd/typo3-realurl/blob/2.6.2/Classes/Cache/DatabaseCache.php#L286

        $row = $this->databaseConnection->exec_SELECTgetSingleRow('*', 'tx_realurl_pathdata',
            'pid=' . (int)$pageId .
                ' AND language_id=' . (int)$languageId .
                ' AND rootpage_id=' . (int)$rootPageId .
                ' AND mpvar=' . ($mpVar ? $this->databaseConnection->fullQuoteStr($mpVar, 'tx_realurl_pathdata') : '\'\'') .
                ' AND expire=0'
        );

Thus in this case ASC is used by default.


Related issues 4 (0 open4 closed)

Related to TYPO3 Core - Task #89194: Upgrade wizard for slugs optimizationsClosed2019-09-18

Actions
Related to TYPO3 Core - Bug #88971: PopulatePageSlugs wizard finds and uses outdated realurl dataClosed2019-08-16

Actions
Related to TYPO3 Core - Bug #89964: PopulatePageSlugs.php should use order in query of getSuggestedSlugsClosed2019-12-16

Actions
Related to TYPO3 Core - Bug #89069: PopulatePagesSlugs should respect tx_realurl_pathsegment fieldClosed2019-09-03

Actions
Actions

Also available in: Atom PDF