Database Links Help

I want to create a dynamic PL/SQL Portlet which displays an image based on a value in a remote database.
Can someone explain how to use Database Links in Oracle Portal and then how to create the public synonym so it can be accessed in the SQL?
I've tried to do it but am unsure which schema to create a DB Link To - Is it the Portal Schema?
any help is appreciated.
Thanks
please note i'm trying to do something like this:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>#title#</title>
</head>
<body>
<ORACLE>
declare branding varchar2(50);
begin
select parameter_value
into branding
from system_parameters
where parameter = 'BRAND';
if branding = '1'
then
htp.p('HTML FOR BRAND 1');
else
htp.p('HTML FOR BRAND 2');
end if;
end;
</ORACLE>
</body>
</html>
System parameters is the table in the remote DB
Thanks!

In the Portal Navigator click on the Database tab.
Create a new schema e.g. BRAND. If you give it a password you can log in directly to that schema using SQLDeveloper, which can be hugely helpful for debugging and testing.
Click on the schema in the list to open it up. Create a new database link. You will need to know a named user and password on the remote database, as well as the SID. The SID must match an entry on the TNSNAMES.ORA file on the application server, which is not necessarily the same as your local PC (this has caught me out far too often...).
Create a synonym for the table SYSTEM_PARAMETERS in your new schema. On the second page you will have to type in the source table name (the pop-up search doesn't work across database links) and also select the database link (it's best to use the popup search for this).
If you use SQLDeveloper to log into your new schema then you should be able to check everything is well by running your select stagement:
select parameter_value
from system_parameters
where parameter = 'BRAND';
Good luck!
Patrick

Similar Messages

  • Database link help in oracle

    i try to get a resultset from database link but its return empty,so i tried to put the tables in the machine and its successed but with links did not.
    can somebody help me.

    database link help in oracleOr perhaps your do! Whoops.

  • HELP! FOR LOOP TO SCROLL THROUGH TABLE AND CREATE DATABASE LINK

    Hi,
    Here's the scenario, not much of a PL programmer, just basic SQL so really need some help people!
    I have 2 tables. 1 contains list of DB's and the other contains rules to follow.
    I need to create a loop that goes through the table containing the DB's and on each row a DB link is created (Only 1 link allowed!)
    Once created, the schema currently logged in with also has an account on the linked DB in order to run scripts- The scripts are stored centrally hence the requirement for the link to the target DB.
    There are numerous scripts that need to be executed and can all be called from 1 script, once executed the loop exists and the database link needs to be dropped.
    Once dropped, the first loop continues, creating a DB link for the next DB listed in the table (and all the scripts are fired again)
    This continues against all the DB's listed in the table.

    Hi BlueShadow,
    Thanks again for the response, you've hit the nail on the head. SQL scripts on a unix server, a loop goes through a table 1 at a time. Each row gets a link created and then all the scripts stored on the server are executed against the db linked to. So I'm assuming this is a loop within a loop.
    1 loop to go through the table to create the link and then another loop within once connected to execute all the scripts against the connected DB. Once the scripts are run, the loop exits and moves onto the next server and so on until all the servers have the scripts are run.
    It's PL/SQL scripts we're after and not shell scripts as this would free us from the OS constraints.
    We have to drop the links due to security. Any idea on o

  • Help with a database link?

    Hiya
    In our environment we have two servers for live and two for test. LIVE01 has db links to all other servers and they all work fine. I cannot get the db links up on test and I'm not sure why..
    Both systems have global_names set FALSE so i can name the link anything I want. Both systems have identical TNSNAMES files and no SQLNET.ORA
    The test systems have database names that do not have a suffice (it's the only significant difference I can find)
    LIVE01 =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.1)(PORT = 1521))
        (CONNECT_DATA =
          (SERVICE_NAME = LIVE01.MYDOMAIN.COM)
    LIVE02 =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.1)(PORT = 1521))
        (CONNECT_DATA =
          (SERVICE_NAME = LIVE02.MYDOMAIN.COM)
    TEST01 =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.2)(PORT = 1521))
        (CONNECT_DATA =
          (SERVICE_NAME = TEST01)
    TEST02 =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.2)(PORT = 1521))
        (CONNECT_DATA =
          (SERVICE_NAME = TEST02)
      )I've connected via RDP to each server, and I can tnsping and sqlplus user/pass@tnsname successfully on both servers, to all instances
    The command I use in sqlplus to create the link on LIVE01:
    CREATE PUBLIC DATABASE LINK live2dblink CONNECT TO user IDENTIFIED BY pass USING 'LIVE02';
    CREATE PUBLIC DATABASE LINK test1dblink CONNECT TO user IDENTIFIED BY pass USING 'TEST01';
    CREATE PUBLIC DATABASE LINK test2dblink CONNECT TO user IDENTIFIED BY pass USING 'TEST02';
    SELECT * FROM ALL_DB_LINKS
    PUBLIC     live2dblink.DOMAIN.COM     USER     LIVE02     2011-04-10 01:26:23
    PUBLIC     test1dblink.DOMAIN.COM     USER     TEST01     2011-04-10 01:26:23
    PUBLIC     test2dblink.DOMAIN.COM     USER     TEST02     2011-04-10 01:26:23SELECT * FROM DUAL@test2dblink ;
    DUMMY
    XBut if I repeat the relevant parts of the setup on test01 to link to the other 3 databases:
    CREATE PUBLIC DATABASE LINK live1dblink CONNECT TO user IDENTIFIED BY pass USING 'LIVE01';
    CREATE PUBLIC DATABASE LINK live2dblink CONNECT TO user IDENTIFIED BY pass USING 'LIVE02';
    CREATE PUBLIC DATABASE LINK test2dblink CONNECT TO user IDENTIFIED BY pass USING 'TEST02';
    SELECT * FROM ALL_DB_LINKS
    PUBLIC     live1dblink.DOMAIN.COM     USER     LIVE01     2011-04-10 01:26:23
    PUBLIC     live2dblink .DOMAIN.COM     USER     LIVE02     2011-04-10 01:26:23
    PUBLIC     test2dblink.DOMAIN.COM     USER     TEST02     2011-04-10 01:26:23SELECT * FROM dual@test2dblink
    error: "tns could not resolve service name"
    I've run out of other things to check - it's not the "global names must match" issue because that's set false and verified with
    SELECT name, value
    FROM gv$parameter
    WHERE (name LIKE '%link%')
    OR (name IN ('global_names', 'dblink_encrypt_login'));
    Yep, it's false..
    I've seen other errors during my fiddling with various parameters, including "end of file on communication channel" when select * from dual@db_link.. as though the test instance kicked the connection from live but for the past half hour, this "cannot resolve" has been the persistent one..

    Try using the full connect string in the database link like this:
    CREATE PUBLIC DATABASE LINK test2dblink CONNECT TO user IDENTIFIED BY pass
    USING '(description=(address=(protocol=tcp)(port=1521)(host=10.0.0.2))(connect_data=(sid=TEST02)))';

  • Need help/info on "database link of same name has an open connection"

    Hello,
    I am trying to create an application on html db (new in html db) to see if I can move data from one database (oracle 9i) say dbdev to another one called dbtest. I want to be able to select the data from html db app and by clicking on a button move them to dbtest ( right now only looking at data from one table ). This is what I have done so far:
    1. created a duplicated table of dbdev into html db with no data.
    2. created package with procedures to
    A. create a database link
    B. delete if there is a record on html db table
    C. go trough a loop (cursor) and get the data from dbdev
    D. drop the database link
    Now, when I do all of the above steps I get an error “database link of same name has an open connection" but when I don’t do the step C. I don’t get this error. So something is wrong in my step C. On my step C, I just open the cursor, do a for loop and insert the records into my html db table.
    Any idea!!!
    Thanks
    More questions to come…..

    never mind, I should not drop the database link with in the procedure.
    thx

  • Database Link question ! Please help me ....

    Hi everybody,
    I have some question about database link.
    For example, I have 3 database, database 1 and database 2 connect together by database link db_link1, database 2 and database 3 connect together by database link db_link2.
    I want to ask: Can I connect from database 1 to database 3 ? ( Of course don't use database link between database 1 and 3, just use database db_link1 and db_link2 )
    Both db_link1 and db_link2 are public database link.
    Can I restrict user access by 2 these public database link ?
    Thanks a lot.

    A database link has directionality-- it connects from one database to another database. It is not a bi-directional link.
    Assuming db_link1 exists in database 1 and connects to database 2 and db_link2 exists in database 2 and connects to database 3, it should be possible to read data that is in database 3 from database 1 without creating a new database link. But you'd need some sort of intermediate layer in database 2 (i.e. a view in database 2 that queries an object in database 3) because you can't nest database links in a single SQL statement. Of course, you would almost never actually do this for a variety of reasons. The only time I've ever heard of someone using this sort of setup is if database 1 is a very recent version of Oracle and database 3 is a very very old version of Oracle such that a database link between 1 and 3 is not possible.
    If you create a public database link, you cannot restrict access to that link short of potentially doing something with VPD. If you're creating a database link using a fixed username & password that would create a security issue, it would make far more sense to create private database links.
    Justin

  • Custom report listing database links

    I'm trying to determine what tables/views in the EM12c repository contain database link information (if any), so I can create a custom report using it.  Has anyone come across an EM schema description or know how to determine what objects/queries are behind a page in EM?  If the data isn't centralized in the EM schema, I recognize I could create a Group and run a query against DB_DB_LINKS to generate a link report for all the databases.  Is that a better way to do it?  I'm open to additional suggestions or tips, since I'm new to the custom reporting features ... (and not trying to reinvent the wheel here).  Thanks.

    There is no table in em repository database that contains db link information for database targets. The way to get this info is create a dblink in your em repository database for each database target then create plsql package that connect to each target over dblink and writes the info into a table in em repository table. You could also just create a sql job from em and run against each database target.
    If you need help with the plsql let me know I have several of these in my em to extract specific data I need from each db target.

  • Interactive report performance problem over database link - Oracle Gateway

    Hello all;
    This is regarding a thread Interactive report performance problem over database link that was posted by Samo.
    The issue that I am facing is when I use Oracle function like (apex_item.check_box) the query slow down by 45 seconds.
    query like this: (due to sensitivity issue, I can not disclose real table name)
    SELECT apex_item.checkbox(1,b.col3)
    , a.col1
    , a.col2
    FROM table_one a
    , table_two b
    WHERE a.col3 = 12345
    AND a.col4 = 100
    AND b.col5 = a.col5
    table_one and table_two are remote tables (non-oracle) which are connected using Oracle Gateway.
    Now if I run above queries without apex_item.checkbox function the query return or response is less than a second but if I have apex_item.checkbox then the query run more than 30 seconds. I have resolved the issues by creating a collection but it’s not a good practice.
    I would like to get ideas from people how to resolve or speed-up the query?
    Any idea how to use sub-factoring for the above scenario? Or others method (creating view or materialized view are not an option).
    Thank you.
    Shaun S.

    Hi Shaun
    Okay, I have a million questions (could you tell me if both tables are from the same remote source, it looks like they're possibly not?), but let's just try some things first.
    By now you should understand the idea of what I termed 'sub-factoring' in a previous post. This is to do with using the WITH blah AS (SELECT... syntax. Now in most circumstances this 'materialises' the results of the inner select statement. This means that we 'get' the results then do something with them afterwards. It's a handy trick when dealing with remote sites as sometimes you want the remote database to do the work. The reason that I ask you to use the MATERIALIZE hint for testing is just to force this, in 99.99% of cases this can be removed later. Using the WITH statement is also handled differently to inline view like SELECT * FROM (SELECT... but the same result can be mimicked with a NO_MERGE hint.
    Looking at your case I would be interested to see what the explain plan and results would be for something like the following two statements (sorry - you're going have to check them, it's late!)
    WITH a AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_one),
    b AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_two),
    sourceqry AS
    (SELECT  b.col3 x
           , a.col1 y
           , a.col2 z
    FROM table_one a
        , table_two b
    WHERE a.col3 = 12345
    AND   a.col4 = 100
    AND   b.col5 = a.col5)
    SELECT apex_item.checkbox(1,x), y , z
    FROM sourceqry
    WITH a AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_one),
    b AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_two)
    SELECT  apex_item.checkbox(1,x), y , z
    FROM table_one a
        , table_two b
    WHERE a.col3 = 12345
    AND   a.col4 = 100
    AND   b.col5 = a.col5If the remote tables are at the same site, then you should have the same results. If they aren't you should get the same results but different to the original query.
    We aren't being told the real cardinality of the inners select here so the explain plan is distorted (this is normal for queries on remote and especially non-oracle sites). This hinders tuning normally but I don't think this is your problem at all. How many distinct values do you normally get of the column aliased 'x' and how many rows are normally returned in total? Also how are you testing response times, in APEX, SQL Developer, Toad SQLplus etc?
    Sorry for all the questions but it helps to answer the question, if I can.
    Cheers
    Ben
    http://www.munkyben.wordpress.com
    Don't forget to mark replies helpful or correct ;)

  • How can you SELECT via Database Link CLOB data using Application Express?

    Customer Issue:
    Developer using Oracle's Application Express 3.1. The Developer is trying to SELECT a CLOB datatype column from a remote (10.2.0.3) database, via a database link on her 10.2.0.4 based client Application. The Developer wants to be able to select CLOB data from the remote database which has limitation that she can't make any changes to the remote database.
    Developer's Comments:
    I do a select and get the error. Getting error ORA-22992: cannot use LOB locators selected from remote tables. So she feels she can't use dbms_lob.substr in this configuration I can do a "select into" but that is for one value. I am trying to run a select statement for a report that brings back more than one row. I do not have permission to change anything on the remote database. I want to access the remote database and multiple tables.
    This is not something I work with, would greatly appreciate help or ideas. Is this a limitation of the 3.1; or does she just not have this set up correctly; or should she be using a Collection (if yes, please share example)
    Thanks very much,
    Pam
    Edited by: pmoutrie on Jun 4, 2009 12:01 PM
    Hello???
    Would really appreciate an answer.
    Thanks,
    Pam

    This may not be a perfect solution for you but it worked for my situation.
    I wanted to grab some data from Grid Control's MGMT$JOB_STEP_HISTORY table but I couldnt' create an Interactive Report due to the existance of a CLOB column. I cheated this by creating a view on the GC DB, grabbing the first 4000 characters and turning it into a varchar2 column:
    create view test_job_step_history as
    select job_Name, target_name, status, start_time, end_time, to_char(substr(output,1,4000)) output
    from MGMT$JOB_STEP_HISTORY where trunc(end_time) > trunc(sysdate)-90
    In an APEX Interactive Report:
    select * from test_job_step_history@GCDB
    Granted, the output looks aweful right now but I am only looking for a very particular output (failed, denied, ORA-, RMAN-, etc) so the formatting isn't the most important thing to me right now.
    If anyone can improve -- and I'm sure you can -- on this I'd love to hear about it.
    Thanks,
    Rich

  • Error in database link(ORA-02063 and ORA-02391)

    Hi
    database link was working fine till this morning. now when i try to query using the database link, i get the following error
    ORA-02391: exceeded simultaneous SESSIONS_PER_USER limit
    ORA-02063: preceding line from RMSLIVE
    It would beof great help if you can advise why this error is occuring.
    many thanks.

    The error stack is quite obvious.
    Either, the profile, with which the database user on remote database is running, must be modified to allow more connections or investigate the session leak in the application talking over database links.

  • Unable to access remote database object using database link

    Hi all,
    I have created a database link to a remote server
    SQL> create database link remote_link connect to lax_dba identified by lax_dba using 'abc.corp.com';
    database link created
    when i am trying to access any table of lax_dba
    sql> select * from laxtab@remote_link;
    i am getting this Ora error
    ORA-12514: TNS:listener does not currently know of service requested in connect
    I need your help please to solve this issue
    Thanks n Regards
    Laxman

    The database server where you defined the link (not your PC) has resolved 'abc.corp.com' to a server/port/service combination using its tnsnames.ora, sqlnet.ora and possibly ldap.ora settings. You can try
    tnsping abc.corp.comon the server (as ReubenC suggested) to see what it's attempting to connect to. (It's important to do this on the database server and not on your PC as they will have different tns settings etc.)
    It has then found the server and found a listener running on it (so you're getting close), but that remote listener doesn't recognise the service you're asking for. It might be something like the '.com' suffix.

  • Problem with using database link from oracle 7 to oracle 9i

    Hi To Every One
    I have two oracle database oracle 7.3.4.0.1 and oracle 9i 9.2.0.1.0.
    and the tns alias to connect to oracle 9i database is oracle9i and tns
    alias to oracle 7 database is oracle7.I have no problem in connect to
    these database using these tns aliases from either database.The tns
    alias for oracle 7 is available in tnsnames.ora file of oracle9i and
    tns alias for oracle 9i is available in tnsnames.ora file of oracle 7.
    So there is no connection problem from each other.Connection is
    working fine for each other but the problem with database links is
    like this
    Problem:
    when i create database link from oracle9i user or public database link
    from oracle9i for oracle7 user like this
    SQL ORACLE9I >CREATE DATABASE LINK ORACLE7 CONNECT TO <ORACLE7USER>
    IDENTIFIED BY <PASSWORD> USING 'ORACLE7';
    OR
    SQL ORACLE9I >CREATE PUBLIC DATABASE LINK ORACLE7 CONNECT TO <ORACLE7USER>
    IDENTIFIED BY <PASSWORD> USING 'ORACLE7';
    The links get created sucessfully but when i write command like
    SQL ORACLE9I> DESC <ORACLE7USER_NAME>.<ORACLE7USER_TABLENAME>@ORACLE7
    I RECEIVE A ORACLE ERROR LIKE
    ORA-12663 SERVICE REQUIRED BY CLIENT IS NOT AVAILABLE ON THE SERVER.
    OR IF MY COMMAND IS LIKE
    SQL ORACLE9I> SELECT <FEILD_NAME> FROM
    <ORACLE7USER_NAME>.<ORACLE7USER_TABLENAME>@ORACLE7;
    I RECEIVE AN ORACLE ERROR LIKE
    ORA-01002 FETCH OUT OF SEQUENCE.
    ORA-02063: preceding line from ORACLE7
    BUT IF I CREATE A LINK FROM ORACLE7 USER FOR ORACLE9I USER
    IT WORKS FINE.
    PLZ HELP ME WHAT IS THE PROBLEM THAT THE LINK FOR ORACLE 7 IS NOT WORKING WHEN
    IT IS BEING CREATED FROM ORACLE9I.
    Thank u.

    Oracle 9.2.0 does not support connectivity to Oracle 7. The newest version that will support this is 9.0.1.

  • Failed to create Database Link in OWB 9.2 for remote SQL Server

    Hi,
    I have to create Database link for connecting to SQL server in a different machine.I am using OWB 9.2 and XP.
    Dataserver is the machine name which is running SQL Server
    I included follwing lines in TNSNAMES.ORA file
    hsodbc.world =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = dataserver)(PORT = 1433)
    (CONNECT_DATA = (SID=hsodbc.world)
    (HS =OK)
    I included follwing lines in Listener.ORA file
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = dataserver)(PORT = 1433)
    (SID_DESC=
    (SID_NAME=hsodbc.world)
    (ORACLE_HOME=C:\ora92)
    (PROGRAM=hsodbc)
    I included follwing lines in inithsodbc.ORA file
    HS_FDS_CONNECT_INFO = testdsn
    HS_FDS_TRACE_LEVEL = 0
    While creating new database link I gave the follwing values
    DB Link Name : Mylink
    SQL * Net Connect String: hsodbc
    User Name: sa
    password:<my password>
    Then clicked "Create and Test" button to get the follwing error message
    Testing...
    Failed.
    ORA-12154 TNS:could not resolve service name
    *Cause: The service name specified is not defined correctly in the TNSNAMES.ORA file
    *Action: Make the following checks and correct the error:
    - Verify that a TNSNAMES.ORA file exists on your repository server
    in the proper place and is accessible. See the operating
    system specific manual for details on the required name and location.
    - Check to see that the service name exists in one of the
    TNSNAMES.ORA files and add it if necessary.
    - Make sure there are no syntax errors in the file.
    Particularly look for unmatched parentheses or stray characters.
    Any error in a TNSNAMES.ORA file makes it unusable. See
    Chapter 4 in the SQL*Net V2 Administrator's Guide. If possible,
    regenerate the configuration files using the Oracle Network Manager.
    Is there anything wrong in my configuration. Please help me in getting out of this problem.
    Thanks in advance
    Andy

    Hi Mark,
    Thanks Mark.I did the changes in the specified .ora file but now it shows a different error message.
    The error is
    Testing...
    Failed.
    Cwm Error Message: SQL Exception
    Cwm Error: SQL Exception
    Class Name: CacheMediator
    Method Name: getDDEntryFromDB
    Repository Error Message: ORA-28545: error diagnosed by Net8 when connecting to an agent
    NCRO: Failed to make RSLV connection
    ORA-02063: preceding 2 lines from MYLINK
    Query: select 1 from dual@MyLink
    I got the same error when i tried manually in sql plus.
    Please help me in getting out of thid problem
    Thanks in advance
    Andy

  • Problems in using database link

    Hi all,
    I have problems in using the following created database link:
    Name: fzanalyze
    User: fzanalyze
    PWD: xxx
    Host: fz.domain.com
    I get the following error message, if I try to start this select:
    select * from tab@fzanalyze;
    FEHLER in Zeile 1:
    ORA-12154: TNS:Couldn't resolve service name
    The problem, the TNS is correct, because I copied the hoststring from the tnsnames.ora. Also I can connect to the database by using the given hostname as follows:
    connect fzanalyze/[email protected]
    connected
    What could be the problem, the I get the tns-Error, although I can connect normal to the database??
    Thanks for helping
    Dana

    Dana,
    Unlike Kamal, I don't use SQLNET anymore (isn't it obsolete from 8i+?), so I don't have any sqlnet.ora on my client or server.
    I'm not really a sysop, so no clever thoughts behind the following ideas, I just use these for development purposes at home:
    IP range at home = 192.168.x.x segment (another router server connects to the internet)
    Oracle server computer name = dbserver.seinpost.nl (local address = 192.168.1.110)
    instance entry in $TNS_ADMIN/listener.ora @ server:
        (SID_DESC =
          (GLOBAL_DBNAME = inst04.seinpost.nl)
          (ORACLE_HOME = /u01/app/oracle/product/10.1.0/db_1)
          (SID_NAME = inst04)
        )instance entry in $TNS_ADMIN/tnsnames.ora @ server:
    INST04.SEINPOST.NL =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = dbserver.seinpost.nl)(PORT = 1521))
        (CONNECT_DATA =
          (SERVICE_NAME = inst04.seinpost.nl)
      )instance entry in tnsnames.ora @ client:
    INST04 =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS =
            (PROTOCOL = TCP)
              (HOST = 192.168.1.110)
                (PORT = 1521)
        (CONNECT_DATA =
          (SERVICE_NAME = inst04.seinpost.nl)
      )So again, no sqlnet.ora and as you can see only on my client I use local IP addresses to prevent my client for searching the internet for the non-existing dbserver.seinpost.nl address
    Hope this helps,
    Michiel

  • DATABASE LINK from 92060 to 102030 issue

    Hi All,
    Question on Database link:
    Database A -- 10.2.0.3.0
    Database B -- 9.2.0.6.0
    Created database link from 10g to 9i and it works fine as expected.
    I tried from BOTH server and also a CLIENT (SQLPLUS from my PC).
    Created databas elink from 9i to 10g and it works fine on server
    for example:
    SQL> select sysdate from dual ;
    SYSDATE
    10-APR-07
    SQL> select sysdate from dual@<<DBLINKNAME>> ;
    SYSDATE
    10-APR-07
    However, I'm unable to connect using SQLPLUS.
    for example:
    Connected to:
    Oracle9i Enterprise Edition Release 9.2.0.6.0 - 64bit Production
    With the Partitioning, OLAP and Oracle Data Mining options
    JServer Release 9.2.0.6.0 - Production
    SQL> select sysdate from dual ;
    SYSDATE
    10-APR-07
    SQL> select sysdate from dual@daspnprd ;
    select sysdate from dual@daspnprd
    ERROR at line 1:
    ORA-12154: TNS:could not resolve service name
    Note;
    =====
    NO change in tnsnames.ora or LDAP.. ALL are identical
    Any known issues???
    Please help!!

    Make sure you are resolving with LDAP, (check the sqlnet.ora contents) and not the local tnsnames. Verify the entry at the OID and verify that the default context being used is correct by specifying a fully qualified net service name or a full LDAP DN as the connect identifier.

Maybe you are looking for