fix for mysql 5.7