In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
1. View dblink
Select owner,object_name from dba_objects where object_type='DATABASE LINK'
Or
Select * from dba_db_links
two。 Create dblink
Premise:
The user who created the dblink has the corresponding database permissions
Create public database link or create database link
Can be used
Grant create public database link,create database link to myAccount; to authorize.
Create public database link dblinkname connect to username identified by password
Using'(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP) (HOST = database_ip) (PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = servicename)
)
)'
If you don't add public after create, the created dblink is not public and only the creator can use it.
Add: how to determine the servicename of the database:
1. Use in sqlplus
Show parameter [s] service_names
Note that both parameter and parameters are fine.
two。 Use
Select name,value from v$parameter where name='service_names'
3. Use db link
For example, if a public dblink of scott_rmthost is created on the local database (using the scott user connection of the remote host), then connect to the local database with sqlplus, and execute select * from scott.emp@scott_rmthot to get the data in the emp table under the scott user on the remote database.
You can also create a synonym locally to point to scott.emp@scott_rmthost, which makes the value much more convenient.
4. Delete
Note: the user has create public database link or create database link permissions.
Drop public database link dblinkname
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.