added ordering of medias in SODA query