Add end date as well to sorting SQL.
Merge pull request #141 from vlad-ghita/patch-1

Add end date as well to sorting SQL.