diff --git a/docs/source/jupyter/multiple_wrappers.ipynb b/docs/source/jupyter/multiple_wrappers.ipynb index 40ae201..5d094cd 100644 --- a/docs/source/jupyter/multiple_wrappers.ipynb +++ b/docs/source/jupyter/multiple_wrappers.ipynb @@ -151,13 +151,14 @@ } ], "source": [ + "from sqlalchemy.engine import URL", "print(\"Input data to connect to Postgres table!\")\n", "user = input(\"User: \")\n", "pwd = getpass(\"Password: \")\n", "db_name = input(\"Database name: \")\n", "host = input(\"Host: \")\n", "port = int(input(\"Port [5432]: \") or 5432)\n", - "postgres_url = 'postgres://%s:%s@%s:%s/%s' % (user, pwd, host, port, db_name)" + "postgres_url = str(URL.create(\"postgresql\", user, pwd, host=host, port=port, database=db_name))" ] }, { @@ -356,4 +357,4 @@ "metadata": {}, "nbformat": 4, "nbformat_minor": 2 -} \ No newline at end of file +}