Can we write an SQL query for getting two different fields from two different databases.Imagine the situation like this!!!
We have two different databases OrdersdB and DeptdB sitting on two different servers.(both the databases are DB2 on AIX-UNIX)
Does the query work like this when you are querying from two diff dBs.How should we set up the DSN for these kind of queries.
Thanks in adavnce,
I have never worked in a DB2 environment and so I don't know if you'd have MS Access available to you. I have used Access to tie two differing DB together so I can query across them. Just setup DSN's and use them in an Access DB to link or import the tables you want. Then query to your hearts delight. I know I've oversimplified but if it works....
Absence of evidence is not evidence of absence
I know for a fact that you can join tables residing in different DB2 databases sitting on the same machine (On DB2 MVS I do this all the time). But if you can do that across different machines, I do not know.
I think that comparing a "real" RDBMS with access is a mistake. With access running on your PC you have one big advantage: The DB engine runs on your machine. This is not the case when you have dedicated database servers. In the case of the question, one of the DB engines must take the lead and query the other database, suck in its data, do the join and present the user with the results.
Since there are tools available in the market to support cross-database joins, I assume that this feature is not standard in DB2.