fixed regsitry statistics variable typo bug
removed database name from sql
Merge fixes for statistics panel