The psycopg2 module content — Psycopg 2.9.3 documentation
www.psycopg.org › docs › moduleCreate a new database session and return a new connection object. The connection parameters can be specified as a libpq connection string using the dsn parameter: conn = psycopg2.connect("dbname=test user=postgres password=secret") or using a set of keyword arguments: conn = psycopg2.connect(dbname="test", user="postgres", password="secret") or using a mix of both: if the same parameter name is specified in both sources, the kwargs value will have precedence over the dsn value.
psycopg2-connect · PyPI
pypi.org › project › psycopg2-connectJul 14, 2021 · Psycopg2 Connect. Connect to postgres servers using psycopg2. Install. pip install psycopg2-connect. Usage. from psycopg2_connect import connectconn = connect(user, host, port, database, password) Project details. Project links. Homepage.