Improve cache hits for column ordering

TJ Banghart · Friday Demos · March 21, 2025 · 2:23

Little fresh code to make sure column reordering takes advantage of the browser cache and keeps a little load off the database.

Try it yourselfThe full week on docsdashboardsperformanceworkbook

Transcript

This transcript is auto-generated. Names and product terms may be wrong.

  1. think I'm next um let's see here you can see it all right um couple small things one's actually a bug fix but um first thing here is if a connection has a session time zone uh we'll Now display that in the debug panel so um hopefully solves or at least alleviates some confusion that users may have of like okay what time zone is this query in um and then potentially we could Plum this through so it's in the UI and it looks nice but for now it's just in the dialect SQL um okay so that's the first thing second thing is some cach hit fixes um specifically with reordering columns excuse me so we have like the query here this is on my local so

  2. I reverted the changes that that we made uh it's a cash hit you would think if I reorder the columns that it would also be a cash hit but it shouldn't be right now so this is the the previous Behavior different orderings of the dimensions cause cash misses um and now that we've set cash for that that ordering it's a cash hit that's cool now if I turn on columns uh column totals that goes away again so now every reordering is a cash Miss which is not great um so that's on my local if I go to playground I have a cach hit on this ordering and now that should be fixed so we're getting cash yeah Okay cool so we get cash hits now

  3. uh on column reordering and then if I turn on column totals the totals have to be a cash Miss and then shouldn't matter what ordering that is either okay so not a super maybe pretty demo but at least we're getting cash hits when we reorder looks good to me yeah the key the key to unlocking like dashboard cubes is literally stamping out every single one of these so it's a big deal to remove every single piece of that and I think it's pretty