Is it possible to get information from another database with an internal connection having a database in SQL and mySql?

I have a project A with mySql base, and I have another project B with msSql. I connected the database from A and the extracted data from B. But now I need to use the internal join for tables in and B. Is it possible to do this with databases on one server and on another server? Any help would be appreciated.

Thanks in advance

+3
source share
2 answers

, . -, MySQL MS SQL Server.
. . -, , , , ;

SELECT *
FROM
  (SELECT ms_column1, ms_column2 FROM MSSQLTABLE) AS mssql
JOIN
  (SELECT my_column1, my_column2 
   FROM openquery(LINKED_SERVER, 'SELECT column1, column2 FROM MYSQLTABLE') AS mysql
  ON mssql.ms_column1 = mysql.my_column1

, .

+2

, , . , PDO PHP, , , . PHP, A B, , PHP .

+1

All Articles