This project is a Trino plugin for connecting to and querying Teradata databases.
- Java JDK 25
- Apache Maven 3.5.0 or higher
- A running Trino 479 environment
- Teradata JDBC Driver (must be installed manually due to licensing)
This project is built using Maven. To compile and package the connector, run the following command in the project root directory:
mvn clean installOn success, a plugin directory containing all dependencies will be created in the target directory, for example, trino-teradata-479.
-
Copy the entire built plugin directory (e.g.,
target/trino-teradata-479/) to the Trino plugin directory. You will need to rename the directory toteradata.cp -r target/trino-teradata-479/ /path/to/trino/plugin/teradata
-
Restart the Trino coordinator and all workers.
Create a new properties file in the etc/catalog directory of your Trino coordinator, for example, teradata.properties. The file should contain the following:
# The name of the connector, must match the plugin's implementation
connector.name=teradata
# Teradata JDBC Connection URL
# Example: jdbc:teradata://<host>/DATABASE=<database>
connection-url=jdbc:teradata://your-teradata-host/DATABASE=your_db
# Connection username
connection-user=your_username
# Connection password
connection-password=your_passwordReplace your-teradata-host, your_db, your_username, and your_password with your actual Teradata database connection details.
After completing the setup and restarting Trino, you can query the Teradata database through the teradata catalog.
此專案是一個 Trino 連接器(plugin),用於連接和查詢 Teradata 資料庫。
- Java JDK 25
- Apache Maven 3.5.0 或更高版本
- 可運作的 Trino 479 環境
- Teradata JDBC 驅動程式(由於授權限制,需要手動安裝)
此專案使用 Maven 進行建置。請在專案根目錄下執行以下指令來編譯和打包:
mvn clean install成功後,會在 target 目錄下產生一個包含所有依賴項的 plugin 目錄,例如 trino-teradata-479。
-
將建置好的 plugin 目錄(例如
target/trino-teradata-479/)完整複製到 Trino 的 plugin 目錄下。您需要將目錄重新命名為teradata。cp -r target/trino-teradata-479/ /path/to/trino/plugin/teradata
-
重新啟動 Trino coordinator 和所有的 worker。
在 Trino coordinator 的 etc/catalog 目錄下建立一個新的屬性檔案,例如 teradata.properties。檔案內容如下:
# 連接器的名稱,必須與 plugin 的實現相符
connector.name=teradata
# Teradata JDBC 連線 URL
# 範例:jdbc:teradata://<host>/DATABASE=<database>
connection-url=jdbc:teradata://your-teradata-host/DATABASE=your_db
# 連線使用者名稱
connection-user=your_username
# 連線密碼
connection-password=your_password請將 your-teradata-host、your_db、your_username 和 your_password 替換為您實際的 Teradata 資料庫連線資訊。
完成設定並重啟 Trino 後,您就可以透過 teradata catalog 來查詢 Teradata 資料庫了。