go to post Thiago Zenaro · Aug 16, 2017 Hi,Take a look at this linkhttp://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=GSQLOPT_optquery#GSQLOPT_optquery_statsSearch for "Display Query Performance Statistics". There you'll have some examples on how to get SQL statistics at runtime