Project

General

Profile

Actions

Bug #32216

closed

OrderBy on translated records doesn't work properly

Added by Alessandro Bellafronte over 12 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2011-11-30
Due date:
% Done:

100%

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

Description

Hello all
I looked for a similar issue in the bugtracker and I wondered that I couldn't find any report for this problem. Im my opinion it shouldn't be an unusual case, so if I'm just reporting a known issue please feel free to delete this report.

Usecase:
I'm trying to get all localized records from the repository ordered by their "title"-attribute.

Problem:
The records are ordered by their title in default language, instead by their translated title.

Possible Cause:
The ordering takes place when the records with sys_language_uid = 0 are requested from db ("ORDER BY"-clause). The language overlay for the current language is done later, without any ordering-reimplementation.

Suggestions:
I'm not sure what's the best way to fix the problem. Sorting the translated record after doing the language-overlay is more an hack than a practicable way to fix this issue, and not performant at all. I hope that anybody has a better idea, how to handle this.


Related issues 3 (1 open2 closed)

Related to TYPO3 Core - Bug #45873: querySettings setRespectSysLanguage or setSysLanguageUid does not workNeeds Feedback2013-02-27

Actions
Related to TYPO3 Core - Bug #77298: Wrong language overlay logic in extbaseClosed2016-07-29

Actions
Related to TYPO3 Core - Bug #84707: Extbase wrongly counting translated objectsClosed2018-04-12

Actions
Actions

Also available in: Atom PDF