Skip site navigation (1) Skip section navigation (2)

Python connection

From: Michael Satterwhite <michael(at)weblore(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Python connection
Date: 2004-04-25 16:29:54
Message-ID: 200404251129.55480.michael@weblore.com (view raw or flat)
Thread:
Lists: pgsql-sql
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Consider the following snippet from a Python module:

	from pyPGSQL import libpq

	cn = libpq.PQconnectdb("dbname='db', host='xxx'")

At this point, I get the error: 

	invalid connection option ", host

If I'm reading the documentation for libpq correctly (it's safe to assume I'm 
not), host appears to be the correct parameter for specifying the server 
running PostgreSQL. What am I doing wrong
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2-rc1-SuSE (GNU/Linux)

iD8DBQFAi+eCjeziQOokQnARAuYUAKCF5WHowC0tlto0IlAhcFpRtranjgCdEUzN
1tjHjkmE8CrSf/6tS2CwoSM=
=Fntg
-----END PGP SIGNATURE-----


Responses

pgsql-sql by date

Next:From: Riccardo G. FacchiniDate: 2004-04-26 07:47:13
Subject: Re: Trigger calling a function HELP ME! (2)
Previous:From: Bruno Wolff IIIDate: 2004-04-24 17:44:37
Subject: Re: Question re: serial

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group