Re: [GENERAL] Any way to make PG driver obey PrintWarn?
am 07.02.2006 00:47:39 von TylerUwe C. Schroeder
> Probably because the notice you see is a notice from the database engine,
> not from the driver. =20
OK, but in order for them to get to my tty, they have to bubble down
=66rom postgres, through the UNIX/TCP socket I am talking to the driver wit=
h,
into DBD::Pg, through DBI, and out through perl's STDERR right? I mean, that
must be right, because if I run my script "2> /dev/null" I don't see this
spam... so it would stand to reason that if DBI provides a "PrintWarn"
option that "controls the printing of warnings recorded by the driver. When
set to a true value the DBI will check method calls to see if a warning
condition has been set."...=20
So it sounds like DBD::Pg isn't thinking to squealch NOTICEs coming
=66rom the server when I ask it to by turning PrintWarn off.
> You can however turn off those notices in postgresql.conf
Sure I can, or I can do "SET client_min_messages=3Derror", but
shouldn't the DBD::Pg driver do that *for* me when I ask not to see
warnings?
Thanks,
Tyler