Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

fikri1510's avatar

How to do mysql join between local and remote database?

I have huge mysql db on the server side, what I want to do is to join local db with remote db. I heard that federated engine will support this action, but it runs slow. What is the best idea to do that sql join?

0 likes
1 reply
bobbybouwmann's avatar

In general I wouldn't want to perform a query over two databases. It's way to small and it also doesn't sound really secure. I rather would perform two separate queries to both databases and then merge the results and do something with that data.

3 likes

Please or to participate in this conversation.