I have a Product class that has many fields on it for ManyToMany, such as ingredients, sizes, species, etc.. A total of about 14 different fields Not all of the fields are a
in the Product entity just also aadd the orderBy to the ingredients relation
/** * ... * @ORM\OrderBy({"some_attribute" = "ASC", "another_attribute" = "DESC"}) */ private $ingredients;