如何将 Presto 数据库连接到 MySQL [英] How to connect a Presto database to MySQL
问题描述
是否可以在来自两个不同 Presto 目录的两个表之间建立连接?假设我在 MySQL 中有一个 product
表,在 hive 中有另一个表 sales_order
;我可以加入他们吗?如果是,那么我如何为 MySQL 指定目录以及我的查询是什么样的?
Is it possible to make joins between two tables from two different Presto catalogs? Assume I have a product
table in MySQL and another table sales_order
in hive; can I join them? If yes, then how can I specify the catalog for MySQL and what would my query look like?
推荐答案
由于 v0.76 Presto 添加了 MySQL 连接器和 PostgreSQL 连接器.
目前,prestodb 无法连接到像 mysql 这样的关系数据库.presto 常见问题中的更多信息:
Since v0.76 Presto adds a MySQL connector and a PostgreSQL connector.
For now, prestodb is not capable to connect to a relational database like mysql. More info in presto FAQ:
Presto 是否连接到 MySQL/PostgreSQL/Oracle?
Does Presto connect to MySQL / PostgreSQL / Oracle?
还没有.我们有一个基本的 JDBC 连接器正在开发中.请注意,这是用于连接到外部 JDBC 数据库.Presto 已经包含一个 JDBC 驱动程序,允许 Java 应用程序连接到 Presto.
Not yet. We have a basic JDBC connector in development. Note that this is for connecting to an external JDBC database. Presto already includes a JDBC driver that allows Java applications to connect to Presto.
这篇关于如何将 Presto 数据库连接到 MySQL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!