Disabling libpq clients stderr output from backend

Started by Oberpriller, Wade D.almost 24 years ago2 messagesgeneral
Jump to latest
#1Oberpriller, Wade D.
oberpwd@nsc-msg01.network.com

Hello,

I have a client C++ program that is built on top of libpq. Whenever I issue
an SQL query that executes a stored procedure that drops tables or creates
tables, I get the NOTICE: messages to appear on the stderr output of my
client propram. Can I turn this off, or redirect it to /dev/null somehow?

Wade Oberpriller http://www.storagetek.com
Software Development Phone: (763) 424-1538
StorageTek: MRDC (800) 328-9108 ext. 1538
wade_oberpriller@storagetek.com Fax: (763) 391-1095

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Oberpriller, Wade D. (#1)
Re: Disabling libpq clients stderr output from backend

"Oberpriller, Wade D." <oberpwd@nsc-msg01.network.com> writes:

I have a client C++ program that is built on top of libpq. Whenever I issue
an SQL query that executes a stored procedure that drops tables or creates
tables, I get the NOTICE: messages to appear on the stderr output of my
client propram. Can I turn this off, or redirect it to /dev/null somehow?

See SetNoticeProcessor (sp?). Plug in a do-nothing processor and you're
set.

regards, tom lane