cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • JMP 19 is here! See the new features at jmp.com/new.
  • Register to attend Discovery Summit 2025 Online: Early Users Edition, Sept. 24-25.
Choose Language Hide Translation Bar

How do I get the psqlodbc driver installed on MacOS?

I'm trying to get the psqlodbc driver (https://odbc.postgresql.org/) installed on an M2 Macbook Pro in order to have JMP connect to a PostgreSQL database within my organization. I was wondering where I can find some documentation on how to do so.

So far, this link (https://odbc.postgresql.org/docs/unix-compilation.html) is all I've found and the commands under its installation instructions involve some files that aren't attached anywhere on the page. I've tried running the command 'brew install psqlodbc' and configure the relevant .ini files, but that hasn't worked either. If anyone has done this before, a rundown/link of the installation process would be greatly appreciated.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: How do I get the psqlodbc driver installed on MacOS?

If you are using JMP 18+ you can use the Python package psycopg to connect to PostgreSQL through Python.  

https://www.psycopg.org

I just ran the code below on my M1 Max MacBook Pro.

 

from jmputils import jpip
jpip('install', 'psycopg[binary]')
/*:
Collecting psycopg[binary]
  Downloading psycopg-3.2.6-py3-none-any.whl.metadata (4.4 kB)
Collecting psycopg-binary==3.2.6 (from psycopg[binary])
  Downloading psycopg_binary-3.2.6-cp313-cp313-macosx_11_0_arm64.whl.metadata (2.8 kB)
Downloading psycopg_binary-3.2.6-cp313-cp313-macosx_11_0_arm64.whl (3.9 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 3.9/3.9 MB 53.4 MB/s eta 0:00:00
Downloading psycopg-3.2.6-py3-none-any.whl (199 kB)
Installing collected packages: psycopg-binary, psycopg
Successfully installed psycopg-3.2.6 psycopg-binary-3.2.6


//:*/
import psycopg

help(psycopg)
/*:
Help on package psycopg:

NAME
    psycopg - psycopg -- PostgreSQL database adapter for Python

PACKAGE CONTENTS
    _acompat
    _adapters_map
    _capabilities
...

View solution in original post

4 REPLIES 4

Re: How do I get the psqlodbc driver installed on MacOS?

If you are using JMP 18+ you can use the Python package psycopg to connect to PostgreSQL through Python.  

https://www.psycopg.org

I just ran the code below on my M1 Max MacBook Pro.

 

from jmputils import jpip
jpip('install', 'psycopg[binary]')
/*:
Collecting psycopg[binary]
  Downloading psycopg-3.2.6-py3-none-any.whl.metadata (4.4 kB)
Collecting psycopg-binary==3.2.6 (from psycopg[binary])
  Downloading psycopg_binary-3.2.6-cp313-cp313-macosx_11_0_arm64.whl.metadata (2.8 kB)
Downloading psycopg_binary-3.2.6-cp313-cp313-macosx_11_0_arm64.whl (3.9 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 3.9/3.9 MB 53.4 MB/s eta 0:00:00
Downloading psycopg-3.2.6-py3-none-any.whl (199 kB)
Installing collected packages: psycopg-binary, psycopg
Successfully installed psycopg-3.2.6 psycopg-binary-3.2.6


//:*/
import psycopg

help(psycopg)
/*:
Help on package psycopg:

NAME
    psycopg - psycopg -- PostgreSQL database adapter for Python

PACKAGE CONTENTS
    _acompat
    _adapters_map
    _capabilities
...

Re: How do I get the psqlodbc driver installed on MacOS?

I you are using JMP 14-17, you still can utilize the package, but you have to install into your Python environment. Working with Python and JMP is much more friendly in JMP 18 and beyond.

Re: How do I get the psqlodbc driver installed on MacOS?

Hello Paul,

 

Thanks for the response. How can I connect to PostgreSQL through native JSL, without Python?

Re: How do I get the psqlodbc driver installed on MacOS?

You need the appropriate iodbc driver installed on your system, and configured for your database connection.  Then you can use JSL to make the connection to the database.  Scripting index is a great source of information. Search for SQL or Open Database

Recommended Articles