Is it possible to use a funtion or subquery to display columns in Table Panel

I recently discovered Grafana and, so far, reading the docs I couldn’t find a way to solve an issue I’m having. First, let me explain the process and then I’ll explain the problem I’m having.

My company has a platform for content and the visits to its content are logged to Elastic Search. Each visit would create an entry to Elastic Search. See an example below:

    "title":"The United Nations world xxx",    

There are more fields but these are the important ones. Each time the title of the content is updated and a new PDF file is added the properties “title” and “pdfImportDateInitial_dates” will have a different value because that’s the title/date at the moment the user is reading the content.

Inside the admin of our system, we offer a Grafana Dashboard with a table panel where the user can see the Title, ID, Language, PDF date and number of visits. As the title and date change, I have the problem you see in the image below:

In the example above I would have to show only one line, with the “xx - newest” title and date and 4 views. It would work as intended if I could retrieve the latest entry from Elastic Search, by datetime desc, and use it’s title and date to fill the respective columns.

Is there any feature of Grafana I could use to achieve this? I’m currently trying transformation but I can’t get a query to return the lastest title and date.

Thanks for any help

1 Like

HI, andreluiz!

Were you able to find a solution to your problem?

I am also searching for a way by which I can get the latest values for a use case that I am working on.

Hello! No, I could never find a solution to this. I also tried on Stackoverflow and nothing so far.