Skip to content
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 use Id() with dbWriteTable() #179

Closed
etiennebr opened this issue Mar 23, 2018 · 3 comments
Closed

Cannot use Id() with dbWriteTable() #179

etiennebr opened this issue Mar 23, 2018 · 3 comments

Comments

@etiennebr
Copy link
Contributor

etiennebr commented Mar 23, 2018

I'm not sure if the issue is in DBI or RPostgres.

library(DBI)
con <- dbConnect(RPostgres::Postgres())

dbWriteTable(con, "mtcars", mtcars)
dbWriteTable(con, Id(table = "mtcars"), mtcars, overwrite = TRUE)
#> Error in (function (classes, fdef, mtable) : unable to find an inherited method 
#> for function 'dbWriteTable' for signature '"PqConnection", "SQL", "missing"'
dbWriteTable(con, SQL("mtcars"), mtcars, overwrite = TRUE)
#> Error: Can't unquote mtcars  # (Works with CRAN version, I think)

I'm using the github DBI and RPostgres versions

krlmlr added a commit to r-dbi/DBI that referenced this issue Mar 26, 2018
- Fix `dbWriteTable()` forwarder for signature `c("DBIConnection", "Id", "data.frame")`.
@krlmlr
Copy link
Member

krlmlr commented Mar 26, 2018

Thanks for reporting. It's both :-o

@krlmlr
Copy link
Member

krlmlr commented Mar 27, 2018

Closed in dc60ae0.

@github-actions
Copy link

github-actions bot commented Dec 7, 2020

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.

@github-actions github-actions bot locked and limited conversation to collaborators Dec 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants