Relations pull data in random order instead of sheet order

@Mark @George_B Is this anything you would want to look at? I have a relation (rel-GasLog and currently rel-GasLogLast10 as well) in my User Profile sheet that is getting matching rows from the Gas Log sheet based on Vehicle ID. For some reason the relation is not pulling back the records in the same order they were added to the Gas Log sheet. Based on the chart above (which is built off of data in the order it was pulled from the relation) you can see that the last 7 rows are always the last 7 rows pulled in from the relation. Whenever I add new rows, they always pull in through the relation before these same 7 rows. If you are familiar with DB2 databases, it acts like the relative record number (RRN) for these 7 rows are much greater than any other row added. This also causes issues when applying a Single Value (Last item) to the relation. The single value does not get the true last row, but instead pulls the 12/11 row every single time. Even if I add new rows to the end of the table with a newer date. This is the part that concerns me the most as it may affect other users that rely on the the Single Value getting the true last row as represented by the data in the data editor, and not a some random row.

I think I could delete these 7 problem rows and the app would work as expected, but I wanted to leave it intact for you to see if there happened to be a bug. I’m in no rush, so you can take a look whenever you have time.

This is also presenting itself as a problem when getting the 10th record from the end as a Single Value (sv-DatePrior10) in the Gas Log sheet that uses a self relation (rel-Self).

It’s acting like the Gas Log sheet has a weird sort order that different from what’s visible in the data editor.

You can preview as Jeff Mobile and select GMC as the vehicle.
Keep in mind that these issues are all within the data editor and with Glide Tables. This is not related to any lists or components that would otherwise allow me to specify a sort order.

P.S. In addition to my Conditional Relations request, being able to sort a relation within the Glide data editor would be beneficial in this case like this. Right now I have to rely on user entering data sequentially, but if they ever retroactively created rows, then it would throw things out of whack.

2 Likes