Details
-
Type:
Improvement
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 2.0-ALPHA3
-
Fix Version/s: 2.0-BETA1
-
Component/s: Mapping Drivers, ORM
-
Security Level: All
-
Labels:None
Description
It should be supported to set a default ordering for associations.
Example:
/** * @OneToMany(targetEntity="Thing", mappedBy="other") * @OrderBy("foo_bar ASC, other_bar DESC") */ private $things;
The value of the orderby mapping declaration should be a simple DQL snippet.
Main classes to adjust for this feature: SqlWalker, StandardEntityPersister and the metadata drivers, of course.