How can I calculate median and percentile in grafana with MySQL data source

How can I calculate median and percentile in grafana with MySQL data source

Looks like mysql doesnt have support for this so you have to work around and calculate it yourself.

This might help: