[Pgsql-ayuda] postgresql python

Alvaro Herrera alvherre@dcc.uchile.cl
Tue, 25 Nov 2003 14:50:19 -0300


On Mon, Nov 24, 2003 at 11:15:40AM +0100, Fernando San Martín W. wrote:
> alguien sabe como capturar en python un mensaje generado con un raise
> notice?

Que biblioteca de conexión estás usando?  Le eché un vistazo a un par
(psycopg y PyGreSQL) y me parece que una de ellas tira los notices a la
salida estandar.  Lo que puedes hacer es reemplazar esa función en la
biblioteca; pero creo que también podrías definir un "notice processor".

El código es bastante legible.

-- 
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
You liked Linux a lot when he was just the gawky kid from down the block
mowing your lawn or shoveling the snow. But now that he wants to date
your daughter, you're not so sure he measures up. (Larry Greenemeier)