you can also put the entire tns entry in the link itself
create database link your_db_link
connect to your_user
identified by your_password
using '(DESCRIPTION=(ADDRESS=(PR
Main Topics
Browse All Topicshi
how to create database link in oracle using static ip
ap
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Anup, DB links and IPs have an intermediate layer in between: TNS
So your question ends up being two-part:
For the first question, you just use your static IP where you would put the host name.
For the second, you create a DB link referencing the TNS alias, or else specify the TNS connection string in place. Both things are done through the keyword USING (sdstuber's 1st and 2nd examples respectively).
Note that you can omit the CONNECT TO ... IDENTIFIED BY ... portion. In that case, remote connections will be attempted with the same credentials you used to connect to your local DB.
Again, it's NOT that DB links have static IPs... it's TNS connection strings that have them :-)
Business Accounts
Answer for Membership
by: sdstuberPosted on 2009-02-17 at 06:14:51ID: 23659648
do you know the port and service/sid name?
= 1521))
if so, add a definition to your database SERVER's tnsnames.ora like this...
YOUR_DB_NAME.world =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = your.ip.address.here)(PORT
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = your_service_name)
)
)
then create a database link inside the database like...
create database link "your_db_link"
connect to your_user
identified by "your_password"
using 'your_db_name'