Change SQL query to uninstall