Install Posit Professional Drivers on macOS


Overview

How to install Posit Professional Drivers for macOS.

Unsupported drivers

The following drivers aren’t supported for use on Apple silicon (M1/M2/M3 chips):

  • Athena
  • Hive
  • Impala
  • MongoDB
  • Oracle

Step 1. Install dependencies

  • Install the unixODBC driver manager. We recommend using Homebrew since it’s the easiest method:

    brew install unixodbc

    If you are working with the Oracle database, you must:

    • Install version 19.21 of the Oracle Instant Client. Either the Basic Package or the Basic Light Package is required.
    • After downloading the zip file, follow the installation instructions for Installing Instant Client 19.x on macOS.

    For more information on connecting to Oracle Databases look at this support article.

Step 2. Install the drivers

Install the drivers using RStudio Desktop Pro:

  • Open RStudio Desktop Pro.
  • In the Connections pane, click New Connection.
  • Select the data source from the list.
  • Specify the installation location of the driver (the default path is /Users/<user>/.local/share/rstudio/odbc/drivers) and click Next.
  • After the installation completes, click Next. The driver has now been installed.
  • You can either:
    • Click Cancel
    • Enter the connection details to test and/or establish a connection.

Installing the drivers this way automatically updates entries in the odbcinst.ini file used by unixODBC.

  • To determine the path to the file, run the following in the terminal:

    odbcinst -j

    The output could resemble:

    unixODBC 2.3.16
    DRIVERS............: /usr/local/etc/odbcinst.ini
    SYSTEM DATA SOURCES: /usr/local/etc/odbc.ini
    FILE DATA SOURCES..: /usr/local/etc/ODBCDataSources
    USER DATA SOURCES..: /Users/username/.odbc.ini
    SQLULEN Size.......: 8
    SQLLEN Size........: 8
    SQLSETPOSIROW Size.: 8

    The DRIVERS... entry shows the location of the odbcinst.ini file.

Step 3. Testing database connectivity

Test the database connectivity directly from RStudio Desktop pro:

  • Open RStudio Desktop Pro.
  • In the Connections pane, click New Connection.
  • Select the data source from the list.
  • Enter the requested information and click Test.
  • If prompted, enter the database password.

If you prefer, you can also set up ODBC DSNs to test and make database connections.

  • Define DSNs in ~/.odbc.ini. For example:

    File: ~/. odbc.ini
    [test]
    Driver = SQLServer
    Server = my.server.name
    Database = dbname
    Port = 1433
    • Then, access the DSN directly from the New Connection dialog or test from the terminal with the following:

      isql test

Upgrading

Installing the latest version of the Professional Drivers replaces the currently installed version.

Uninstallation

Uninstall the drivers using RStudio Desktop Pro:

  1. Open RStudio Desktop Pro.
  2. Within the Connections pane, click New Connection.
  3. Select the data source from the list.
  4. Click Uninstall….
  5. When prompted to uninstall the driver, click Yes.

This removes the driver files and deletes the driver entry from odbcinst.ini.

Back to top