fixes sql for general searches with small molecule results