Cloudwatch insights query - dynamic sort

I have a basic insights query in Grafana

stats count() as total, sum(ExecTime) as ExecTime by Namespace
| limit 50

When I click on a heading in the table results, it sorts based off of the current 50 results.

Is it possible to get Grafana to reload the data by dynamically changing the query? Eg if I clicked on the ExecTime column the query would be

stats count() as total, sum(ExecTime) as ExecTime by Namespace
| limit 50
| sort ExecTime

and if I clicked on it again it would be

stats count() as total, sum(ExecTime) as ExecTime by Namespace
| limit 50
| sort ExecTime desc