gilabean
asked on
Database Link In MySQL
Hi people,
Something that I need to find out about the MySQL database ability.
I'm just wondering whether the MySQL database have any functionality similar to the "database link" in oracle?
Actually I have 2 database here. Let's give it a name of "A" database and "B" database.......
Inside the "A" database there is an employee table.
The program that I am writing now is actually using the "B" database but I need to cross reference to the employee table
in "A" database to get some information.
In order not to use 2 simultaneous DB connection in my program, I am just wondering is there any capability that MySQL
had that can clone out a table in "B" database but that table is actually referring to the employee table in "A" database.
I'm just wondering whether is there any ways of doing this in MySQL ? Thanks in advance for any help that I could get here.
:D
Cheers,
Simon.
Something that I need to find out about the MySQL database ability.
I'm just wondering whether the MySQL database have any functionality similar to the "database link" in oracle?
Actually I have 2 database here. Let's give it a name of "A" database and "B" database.......
Inside the "A" database there is an employee table.
The program that I am writing now is actually using the "B" database but I need to cross reference to the employee table
in "A" database to get some information.
In order not to use 2 simultaneous DB connection in my program, I am just wondering is there any capability that MySQL
had that can clone out a table in "B" database but that table is actually referring to the employee table in "A" database.
I'm just wondering whether is there any ways of doing this in MySQL ? Thanks in advance for any help that I could get here.
:D
Cheers,
Simon.
There is no such capability in MySQL currently. You can use two connections in an outside language, or copy a snapshot of the table in question over to server A from server B and then run the query.
Or...
Link both of the tables into access and use ODBC to access them.
Or...
Use the Easysoft SQL Join Engine (quite expensive though) to hetrogeniosuly join the two tables in a virtual database. The tables can be from entirely different sources too (say mysql and sqlserver)
http://www.easysoft.com/solutions/0001/main.phtml
I am an ex-employee of Easysoft but dont let that put you off - its an excellent product.
Link both of the tables into access and use ODBC to access them.
Or...
Use the Easysoft SQL Join Engine (quite expensive though) to hetrogeniosuly join the two tables in a virtual database. The tables can be from entirely different sources too (say mysql and sqlserver)
http://www.easysoft.com/solutions/0001/main.phtml
I am an ex-employee of Easysoft but dont let that put you off - its an excellent product.
Hmm, the join engive is a neat looking idea.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Hmm, seems the rest of us made an assumption that the databases would be on seperate server machines.
Gilabean: Lowfatspread is right. As long as both databases are on the same physical server, use the mydatabase.mytable.mycolum n syntax.
Gilabean: Lowfatspread is right. As long as both databases are on the same physical server, use the mydatabase.mytable.mycolum