Hi Everyone, We are seeing some strange behavior when we are populati

Certified Lead Developer
Hi Everyone,

We are seeing some strange behavior when we are populating a grid using a queryEntity inside of the with instead of a todatasubet. If we sort on a column that has all of the same data on the first page, and the same data on a couple rows on the second page, there are some rows that are never actually displayed on the grid. Our current theory is that this is occurring because there is no secondary sort field with a queryEntity, and the videos that I will link to later seem to support that. It looks like a query rule will have a secondary sort based on the "Sort query results by" configuration in the query rule itself if you change the pagingInfo.sortInfo that is passed into the query rule. Unfortunately, a queryEntity actually breaks if you pass it a pagingInfo that has an array of sortInfo, so I do not see a way to define, or force, a secondary sort field. According to documentation, it looks like sorting on multiple colum...

OriginalPostID-177486

OriginalPostID-177486

  Discussion posts and replies are publicly visible

  • 0
    Certified Lead Developer
    Ah my mistake, in the code I was testing this on I didn't realise the grid data has additionally been passed through todatasubset() which will accept a paginginfo() with multiple sorts and therefore my grid "trick" works. I think Andrew's suggestion may be the only way forward for you... or you could just disable the sort capability of your low cardinality columns!
  • 0
    Certified Lead Developer
    Thanks, Tim. Yeah it looks Andrew's idea is currently the best solution, but it may not be applicable to us because of the large set of data that we are returning. Not to mention we will have to fix this in multiple locations and with many other views. I am still going to give it a shot, but I am afraid we won't be able to actually implement it. Thank you for your input!
  • 0
    Certified Lead Developer
    No problem it's an interesting topic... or more interesting than Strictly Come Dancing anyway! Consider your use case and if disabling user controlled sorting on your grid, sometimes technical needs out weigh user experience!