Cross-library association in mysql query different libraries on the same machine

For querying data from different databases deployed on the same machine.

The first is that the user to be connected can access the two databases at the same time, and the scope of the database user permissions for this database.

sql query method

select a.id ,b.name from db1.a  left join db2.b on a.id=b.cid

 

 

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326759415&siteId=291194637