I've created a simple report in which I would like the rows to be sorted by submission date. The sorting does not work and results are slightly out of order; the results are generally in some kind of order, but some newer entries are not on top (descending) as expected (see screenshot attached).

I've tried the stable version of this module as well as the development version, and the behavior is the same.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Vako’s picture

In the Webform Report criteria, you need to add the Submission Date and Time columns (make then hidden, if needed).
Then in the Sort options, choose these two fields and make them ascending or descending, as you wish.

MaffooClock’s picture

I've tried that before thinking that might be the key, but it didn't seem to make a difference. I already had the submission date column, so I added the submission time column and made it hidden. Items were still not sorted correctly.

MaffooClock’s picture

FileSize
29.95 KB
66.72 KB

I meant to include screenshots in my previous post.

Vako’s picture

The only difference I see is the Date format should be YYYY/MM/DD also clear the cache.

I have done numerous such reports and it always works flawless, putting the latest entries at the top of the report.

MaffooClock’s picture

I prefer the date to be formatted in a way that the end user will recognize, thus, mm/dd/yyyy. However, I tried it your way, and I got exactly the same results (cache was cleared, too -- I use drush).

I should note that I've spent several hours fiddling with this before opening this issue because I wanted to be sure that I wasn't doing something wrong. Nothing I change seems to affect the behavior. However, I will admit that I am surprised no one else has submitted this issue before me, so that does make me think this might be an isolated issue.

[Incidentally, there are other issues I'm facing, such as filters not working for text fields with "is empty," among others, but I'll open separate issues for those if I can't get past them.]

Vako’s picture

You can always add another date column and hide the one used for sorting.
But your issue seems to be odd. I never had an issue with sorting, but admit that the process need to be refined and be more user friendly.

TBarina’s picture

Issue summary: View changes

I've the same problem. I tried different combinations as suggested above but with no luck.

To tell the truth (and this is even more strange) ascending order on date field seems to work correctly but descending order does't work.

Did you check whether is the same at your site?

Best regards