Results 1 to 3 of 3
  1. #1
    Join Date
    May 2009
    Location
    Manila, Philippines
    Posts
    16

    Unanswered: Setting up a database link

    Hello guys I just wanna ask since a developer has been bugging me for days. He wants me to set up a database link to another oracle database and I've created it using the statement below:

    CREATE DATABASE LINK <db_link name> CONNECT TO <username> IDENTIFIED BY <passwd> USING <'SID'>;

    I've created it successfully and tried using the dblink with different sql statements and its working fine. However this developer told me that it is working on SQL statements like the one below:

    select count(*) from all_objects@db_link;

    But when he runs his application he told me that he must ran the application without the db_link parameter because if he ran it with that parameter it returns an error. Now my question is, since I'm not really a developer, is it possible to link to oracle databases without using the db_link parameter in the statements? Are there ways to directly connect from an oracle database to another oracle database and use the objects for a certain user? Please enlighten me. Thank you very much.

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >is it possible to link to oracle databases without using the db_link parameter in the statements?
    I do not think it is possible.

    >if he ran it with that parameter it returns an error.
    Post SQL & results by using CUT & PASTE.

    How is the database "decide" which remote database is to be accessed when no @db_alias is actually specified.

    Ask this duhveloper provide you the SQL to establish his "requirement"
    & provide SQL that would verify desired functionality.

    Post his responses back here.
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  3. #3
    Join Date
    Jun 2004
    Location
    Liverpool, NY USA
    Posts
    2,509
    simply setup a synonym. for example

    create synonym emp for emp@db_link;

    select * from emp;
    Bill
    You do not need a parachute to skydive. You only need a parachute to skydive twice.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •