Text data in stat panels?

Is it practical to display text-based values in Stat panels (multistat)? It seems like it’s heavily oriented towards numbers only.

I’m trying to display data from a time-series source in a dashboard. The data’s being presented as a repeated series; for each item in the series, I also want a simple, but easily visible, “header”. At the moment I have it displaying some summary info, but I’d like it to display the NAME of the item that’s repeated which would make it much easier to recognize what item in the repeat I’m looking at.

I can display the text data, but:

  • Since I’m displaying the latest entries from a time-series source, and within a time range set elsewhere in the panel, I’m having to group by “time” field.
  • When I do that, it always displays a “time” field(s) in the stat panel along with the data I actually want to display.
  • I don’t see any way to filter out that field from my results, except to set “Fields” to only “Numeric Fields”, or one specific field. For formatting reasons I was trying to display multiple values in one stat panel, which otherwise works great. But it’s either numeric fields only, or everything, as far as I can tell. Transforms just bomb out.

Is there a way to do what I’m looking for? Something it sounds like I’m doing stupid? A better panel type? I like the formatting controls and flexibility of the stat panel.

There’s been other times when I want to display text values in stat panels as well (so not just this use case). I just can’t think of any offhand at the moment =)

Can you provide a small snippet of your data in the time-series source that you are querying? I use Stat panels to display words like OK, Caution, etc. based on the numeric value being observed (or calculated). But maybe you have 1000s of words that you wish to display.

Thanks grant2. It’d be something simple like:

Time Hostname Uptime RAM Used Whatever

2021-03-... SomeName 123456 47600 OtherField...

My data presented to each panel will already be limited to a single Hostname since that’s my Repeat field in the dashboard. I’m then displaying the latest for several other values (with different queries)

I guess what maybe could work for me is just isolating this one value to its own stat panel, then displaying other fields in another (at the moment I’m doing just the latter and it’s working well). Then since I can select a SINGLE value to display, select Hostname in that Statpanel. But I’m wondering if there’s another way.

However, one of the use cases I’ve had is like you brought up - display “OK” or some text value for certain fields. But as soon as I do that, I can’t filter out the “time” field without splitting each into their own statpanel. Which seems opposite of what a “multistat” panel would be for, so feel like I’m missing something.

I think I’ve figured it out. Each of my queries in the stat panel was being Formatted as a Time Series, which is why things I was trying to Transform (like “Organize fields” to eliminate display of Time fields) were failing. Converting to Table formatting for my queries (and a few other changes) gets me what I want.

Once again writing it all out dislodged the part of my brain that was stuck =)

OK, sounds good. I checked and I am formatting my queries as Time Series and it works for me. Here is what I do to get text in my Stat panels:

  1. Create two queries (one called “Actual” and one called “Setpoint”)
  2. Calculate the difference of the two
  3. Compare the value calculated in #2 to the thresholds (which in my case, > 0.05 means Alarm and < 0.05 means OK).
  4. Set value mappings like that shown below.

Gotcha. Your case won’t work for me it sounds like - in my case the data is already text, you’re interpreting a number and displaying text. Which I do in places, but not really related to what I was trying to do here.

For the record, I ended up doing something like:

  • Use modern multiStat panel
    • Calc last (not null), show All Fields, other settings as needed
  • Format queries as table (instead of time-series). I needed this on one panel to get tags to be presented as fields. I don’t totally understand the details here and need to spend some time learning here. Should work as time-series too otherwise.
  • Do an “Outer join” transformation for stat panels which had multiple queries
  • Use “Organize Fields” transformation to hide timestamp or any other field I was accumulating in my queries but didn’t want to display

It was pretty straight-forward overall (I guess), not sure why I was fumbling with it for a while.

1 Like