Refactored getMySQLVersion()