YMatrix
Quick Start
Connecting
Benchmarks
Deployment
Data Usage
Manage Clusters
Upgrade
Global Maintenance
Expansion
Monitoring
Security
Best Practice
Technical Principles
Data Type
Storage Engine
Execution Engine
Streaming Engine(Domino)
MARS3 Index
Extension
Advanced Features
Advanced Query
Federal Query
Grafana
Backup and Restore
Disaster Recovery
Guide
Performance Tuning
Troubleshooting
Tools
Configuration Parameters
SQL Reference
Federated queries allow YMatrix to access external data sources such as MySQL, PostgreSQL, and other databases. The process of reading and writing data is similar to accessing internal tables in YMatrix.
Federated queries are implemented using Foreign Data Wrapper (FDW). FDW is the PostgreSQL implementation of the SQL/MED (SQL Management of External Data) standard. It provides a unified set of public interfaces that enable extensions to deeply integrate with core components of Postgres, including query optimization, execution, scanning, updates, and statistics. This integration allows external data sources to be queried and manipulated directly using SQL statements. For example, with FDW for MySQL, you can directly query, sort, group, filter, join, insert, and update MySQL data just like working with local tables. The community has developed many FDW extensions supporting common databases, as well as access to local files, HDFS, and more.
This section describes how to use FDW to access PostgreSQL, MySQL, and MongoDB, and how to use PXF to access HDFS, Hive ORC, and other data sources.