How to use RStudio Preview 1.2 to connect the ODBC driver for Impala

I find RStudio Preview 1.2 can connect the ODBC driver for Impala in the connection feature.


Here I select the buttion for Impala.

But I don't know how to write some arguement like host, port in this windows.
Here is my information in the ODBC Admin application.
odbc_impala04

You see this in the connection pane because driver is configured in your system.

You need to look at the documentation to see how to connect to impala.
Here some from R
https://db.rstudio.com/databases/impala/

con <- DBI::dbConnect(odbc::odbc(),
                      Driver = "[your driver's name]",
                      Host   = "[your server's path]",
                      Schema = "[your schema's name]",
                      UID    = rstudioapi::askForPassword("Database user"),
                      PWD    = rstudioapi::askForPassword("Database password"),
                      Port   = 21050)

and after you have the official impala documentation
https://www.cloudera.com/documentation/other/connectors/impala-odbc/latest.html

This is no different from R than any other tool so you need to find some example around you to connect to a database.

You can also configure a DSN to add a button in the connection pane directly to your database
https://docs.microsoft.com/en-us/sql/odbc/admin/managing-data-sources?view=sql-server-2017

1 Like

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.