fix mysql check duplicate metric