Merge pull request #14631 from laurocaetano/fix_count_with_order

Ignore order when doing count.