30 May 2016
ContractedPlan.all.order(:user_id, start: :desc).select('DISTINCT ON(user_id) *')