I'm getting the error on the following:
SELECT AVG(((dateupdated-datecreated) + 0.0) / (DURATIONMILLIS + 0.0)) AS "Ratio" FROM "mip*" WHERE key = 'ottvod' AND WORKFLOWSTATUSID = 0 GROUP BY 'PROVIDERID'
Elasticsearch SQL is (I suppose understandably, not very well documented) so I cant find a way around this err.