fixed sql request in TMS Monitor