-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cannot suppressMessages() for SQL Raise Notice #208
Comments
Thanks. Need to provide a notice receiver that forwards to |
@austensen while not optimal (in case you weren't aware of this), you can suppress it on the postgres side with: DBI::dbExecute(con, "drop table if exists quux")
# NOTICE: table "quux" does not exist, skipping
# [1] 0
DBI::dbExecute(con, "drop table if exists quux")
# NOTICE: table "quux" does not exist, skipping
# [1] 0
DBI::dbExecute(con, "set client_min_messages to WARNING")
# [1] 0
DBI::dbExecute(con, "drop table if exists quux")
# [1] 0
DBI::dbExecute(con, "drop table if exists quux")
# [1] 0 (repeated just for demonstration). I found this in https://stackoverflow.com/a/3531274. (Ultimately it would be awesome to be able to capture this into a |
Thanks @r2evans That's helpful to know! |
Requires RcppCore/Rcpp#1145. |
- Postgres `NOTICE` messages are now forwarded as proper R messages and can be captured and suppressed (#208).
This old thread has been automatically locked. If you think you have found something related to this, please open a new issue and link to this old issue if necessary. |
The messages created from
RAISE NOTICE
cannot be suppressed withsuppressMessages()
.It would be nice to be able to suppress these messages for "if not exists" type statements.
Created on 2019-01-25 by the reprex package (v0.2.1)
Session info
The text was updated successfully, but these errors were encountered: