Changing the table quoting with SQL Translation

it looks like the magic incantation requires telling SQL Server to allow quoted identifiers:

DBI::dbExecute(con, "SET QUOTED_IDENTIFIER ON")

Shout out to @krlmlr for having documented this in an odbc github issue! Thank you!

Also worth noting the RJDBC hints at the bottom of this page: Solutions - Microsoft SQL Server

in particular this:

  • RJDBC support - Even though it is not considered an issue, we have found a workaround. The approach is to point the current JDBC connection to the MS SQL translation inside dbplyr :
  sql_translate_env.JDBCConnection <- dbplyr:::`sql_translate_env.Microsoft SQL Server`
  sql_select.JDBCConnection <- dbplyr:::`sql_select.Microsoft SQL Server`

Please refer to the Issues section in dplyr to find out the latest regarding bugs and resolutions.

6 Likes