fixes quoting issue for DB insert
fixes connection details issue