Trino is an open source distributed SQL query engine designed for interactive analytic workloads. In this article, we will see how to connect Trino data in Power BI or other ODBC Apps that do not support direct JDBC connectivity. We will use ZappySys JDBC-ODBC Bridge for seamless integration with any JDBC driver like Trino.
Prerequisite
- Download and Install Docker with Trino Image (See detailed instructions in the next section)
- Download and Install ZappySys JDBC-ODBC Bridge
- Download Trino JDBC Driver. Here is the official Trino JDBC Driver page in case you like to read more.
- Refer to Video On this page for Basic Instructions on Java Install / Driver Setup
Installing Docker Desktop on Windows
For this demonstration, we’ll use a Trino instance running locally on Docker Desktop. In a real-world scenario, your Trino instance might be a managed service or run as a container or VM on a remote server or cloud service.
Step 1: Check System Requirements
- If you are running Windows 10, then the Pro or Enterprise version (64-bit) is preferred, as Docker Desktop relies on Hyper-V and WSL 2 for Windows.
- Virtualization should be enabled in your BIOS.
Step 2: Install Docker Desktop
- Download docker for windows from the official site and install
- Docker Desktop requires Windows Subsystem for Linux 2 (WSL 2) to run. The installer will prompt you to enable WSL 2 if it’s not already enabled (it will also restart your machine).
Docker Desktop installs WSL 2 automatically, but if you encounter any issues, you might need to enable it manually.
Step 3: Enabling WSL 2 manually (optional)
If Docker Desktop failed to install WSL 2 on your machine, you can still do it manually using PowerShell. Open PowerShell as Administrator and run these commands (you may need to restart your machine):
Enabling a modern WSL
wsl --install
You can find more information in WSL Documentation.
Enabling an older version WSL
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
You can find more information in WSL Documentation.
Setting WSL 2 as the default version
After enabling WSL, run the following command to set 2
as the default WSL version:
wsl --set-default-version 2
Installing and Running Trino Image in Docker
We will use a Docker image for this demo to host a sample Trino instance. In the real world, it can be hosted on a remote machine, cloud container, or Virtual Machine.
Verify Trino connection
Once Trino is running, you can confirm or start via the command line, too
Setting up Trino ODBC Connection
-
Open the ODBC Data Source by typing “ODBC” in the search box and launching the ODBC Data Source.
-
To gain access for yourself or other users, go to the User DSN or System DSN. Go to the System tab for SQL Server Integration and add a new System DSN. Click the “Add” button.
-
From the Driver list Select ZappySys ODBC Driver. For this example, select [ZappySys JDBC Bridge Driver].
-
Configure Trino ODBC connection like below and then click Test Connection
-
Go to Preview Tab to query sample data.
-
Click OK to save ODBC DSN.
Loading Trino Data in Power BI using JDBC-ODBC Connection
Now, we can use the ODBC Connection created in the previous step using the below steps. You can also enter a Direct Connection String in Power BI if you do not wish to use DSN.
-
Open Power BI Desktop and click Get Data.
-
In the Get Data window, search for ODBC, select it, and click Connect.
-
Select Trino DSN created in the previous section and click OK
-
If prompted, authenticate using Windows Authentication or the required credentials, then click Connect.
-
Choose Table you like to import (you can also enter custom Query (for query import see steps#3, expand Advanced options). Click Load
Conclusion
We saw how easy it is to connect Trino in Power BI or any other Non-Java apps. Click here to download ZappySys JDBC Bridge Driver and integrate JDBC Driver data in any Non-Java or ODBC Apps (e.g. Excel, Power BI, MS Access), enabling smooth data integration for reporting and analysis. If you encounter any issues or need further assistance, please get in touch with the ZappySys support team.