""" Tested with Pop OS (an Ubuntu clone) # **INSTALLATION**: ## Install Python dependencies * pip install jaydebeapi # latest version was '1.1.1' at the time of writing the gist * pip install JPype1==0.6.3 # IMPORTANT! (latest: 0.7.2 did not work) ## Get the Persavive SQL driver You can get it here: https://esd.actian.com/ You will have to select "Actian Zen (SQL)" as product and choose the correct version and platform. You should end up with 3 files with the extension .jar. Those are drivers for the database written in Java. They are meant to be used with JDBC (https://en.wikipedia.org/wiki/Java_Database_Connectivity). ## Install Java SDK Look it up on the net. """ import jaydebeapi import jpype as jp import os import pandas as pd # optional, pip install pandas # CHANGE THIS!! user = 'USER' password = 'PASSWORD' host = 'EXAMPLE.COM' db = 'DATABASE' # the files with the extension ".jar" must be in the same folder as the script!!! classpath = os.pathsep.join((r"jpscs.jar", r"pvjdbc2.jar", r"pvjdbc2x.jar")) jp.startJVM(jp.getDefaultJVMPath(),"-ea", f"-Djava.class.path={classpath}") # connect con = jaydebeapi.connect(jclassname="com.pervasive.jdbc.v2.Driver", url=f"jdbc:pervasive://{host}:1583/{db}?transport=tcp", driver_args=[user, password]) # query # CHANGE query AND params! query = 'SELECT * FROM SOME_TABLE WHERE user_id=?;' params = [100] df = pd.read_sql(query, con=con, params=params)