PyGreSQL and HTML

Oliver Vecernik vecernik at aon.at
Tue Jan 14 02:55:38 EST 2003


Dave Roberts schrieb:
> Does anyone know how to shift postgres into html table mode from inside
> PyGreSQL?
> 
> From inside postgres it's simple:  \pset format html
> 
> However, all my attempts to pass postgres that string from inside
> PyGreSQL seem to get trapped by the interpreter.  I'm trying to use
> python cgi scripts to present queries, and since the output is going to
> stdout (the browser), if I could just kick postgres into html it would
> be self-presenting.

Yep, but I think it' not possible, because as far as I know this is a 
function of psql and not the database server itself.

Oliver





More information about the Python-list mailing list