DBAsupport.com Forums - Powered by vBulletin
Results 1 to 4 of 4

Thread: db_link error

  1. #1
    Join Date
    Feb 2001
    Posts
    23
    hi
    i create db_link using syntax

    create database link <link_name>
    connect to <username> identified by <pwd>
    using <'service_name'>;

    when i issue a command like
    select * from <able_name>@<link_name>;

    i get this error
    ....TNS: could not resolve service name....
    how can i fix this ...do i have to change something on INIT.ORA and TNSNAME.ORA????????

    thanks

  2. #2
    The service name is an alias in the tnsnames.ora on the server.
    You are not putting < and > , right? :)
    And the select would be
    create database link some_db_link_name connect to some_user_name identified by the_password_of_some using 'some_alias_in_tnsnames';

    select * from some_remote_table@some_db_link_name;

    Hope it helps.
    Ramon Caballero, DBA, rcaballe@yahoo.com

  3. #3
    Join Date
    Feb 2001
    Location
    Bangalore, India
    Posts
    109
    May be a problem in tnsnames.ora. Make sure that tnsnames.ora is on the server.

  4. #4
    Join Date
    Aug 2000
    Posts
    163

    db link

    1)try to ping and tnsping your remote db to eliminate networking problems. If you get expected responses your network is doing good.
    2)try to connect to your remote database using sqlplus.
    if it lets you in there are no problems with your tnsnames.ora. That will be another good thing.
    If there are problems with two checks above resolve them first. If there are no problems and your db link doesn't work post your error message here and we'll try to help.

Posting Permissions

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


Click Here to Expand Forum to Full Width