Added sorting of record set data.