Feature Idea: NRQL Derivative Function

Hi,
I have a cumulative value which I store to insights every minute.
I would like to get the derivative of the value but it there is no derivative function in NRQL. Is this possible/forthcoming?

Eg Dynamic_sql_stmts is a cumulative count since the db started. I’d like to know dynamic_sql_stmts per minute.

SELECT average(DYNAMIC_SQL_STMTS) FROM DB2Stats SINCE 30 MINUTES AGO TIMESERIES 1 minute


New Relic edit

  • I want this, too
  • I have more info to share (reply below)
  • I have a solution for this

0 voters

We take feature ideas seriously and our product managers review every one when plotting their roadmaps. However, there is no guarantee this feature will be implemented. This post ensures the idea is put on the table and discussed though. So please vote and share your extra details with our team.

Try max - min for a hack. You might have to widen your interval.

1 Like

@charekc and @eschumac - Thank you for pitching in the community! I have created a poll so we can start collecting votes for this! :blush:

Hi all,

I’m afraid that the max() - min() hack will not work for me, as I have more than one host (so max and min will be selected from all values for all hosts). I want to calculate the difference between max and min for a host and then sum up all the differences for all hosts. This feature would be really handy for this I think.

1 Like

Absolutely @l.lepkowski - I’ll get your feedback added in to a +1. Thanks for positng.

1 Like

Hey folks! @charekc @l.lepkowski @6MM

Quick update to say that the Derivative function has been added to NRQL capabilities.

See the docs for that here:

https://docs.newrelic.com/docs/query-your-data/nrql-new-relic-query-language/get-started/nrql-syntax-clauses-functions#derivative

2 Likes