Re: database links



Ike wrote:

Can someone show me how I might be able to connect to two separate
databases, and create a query from the two? I understand in Oracle this is
referred to as "database links" but is there a more general way to do this
(i.e. will work with, say, mysql and other DBs?) I want to comapre a field
that is present in two separate files on two seperat databases. Thanks,
Ike

Hi Ike,

AFAIK this cannot be done in a general reliable way.
Of course, you can always make 2 connections, pull in all the data you need,
and join/filter/etc the tables/results yourself in PHP (or whatever it is
your SQL-query should be doing).

Some databases however offer the possibility to make queries that span more
databases of the same kind, eg Oracle or Postgres. I think M$ Access can do
it too.

Maybe there are packages out that facilitate multiple different database
queries, I don't know them.
Possibly, if you make 2 ODBC-connections you can use them both. (not sure
either)

Whatever solution you find, I expect that the performance of such queries
will be low, simply because the data has to be gathered from different
places and cannot be run in one place unless all the data is pulled in,
which is also a lot of overhead.

I would approach this as I described above, just make 2 or more connections,
get in the data you need, and optimize where you can. At least you know
excactly what is going on in that way and you can use your knowledge of the
systems to optimize (eg, not pulling in all the data from all related
tables).

just my 2 cent.

Good luck.
Regards,
Erwin Moller
.



Relevant Pages

  • Re: Need your help [arguments for open source databases]
    ... >> I would like to have your opinions about open source databases versus ... >> in the universe of relational databases. ... The main difference between PostgreSQL and Oracle is manageability. ...
    (RedHat)
  • US-PA: Newtown - Junior to Mid-Level Oracle DBA
    ... Inc. is seeking an experienced junior to mid-level Oracle DBA to support multiple highly available transactional and data warehouse databases underpinning a 24x7 global web services application. ... Position responsibilities consist of both operational and application support primarily in a Red Hat Linux environment. ...
    (comp.databases.oracle.marketplace)
  • US-PA: Philadelphia Area - Junior to Mid-Level Oracle DBA (FT Permanent)
    ... Inc. is seeking an experienced junior to mid-level Oracle DBA to support multiple highly available transactional and data warehouse databases underpinning a 24x7 global web services application. ... Position responsibilities consist of both operational and application support primarily in a Red Hat Linux environment. ...
    (comp.databases.oracle.marketplace)
  • RE: Server Explorer & Databases
    ... As for the visual studio's database server explorer, ... oracle, visual studio generally use the OLD DB provider which is for Oracle ... and support of most general funcctionalitis in latest version of Oracle. ... #Server Explorer for Oracle Databases ...
    (microsoft.public.vsnet.ide)
  • Re: Weird listbox issue (Gupta(SqlWindows), Oracle)
    ... MVk - Monika V. kycka schreef: ... Client has 2 Oracle 10g databases - test and real. ... But application retrievs only first number value leaving string empty. ... And instead of testing all kind of modifications to your code, I suggest you try to find the difference in the databases. ...
    (comp.databases.oracle.misc)