the background of the story is this: a project about 4 projects at the same time development, in my own project need to make a report, but to access another project connected to the DB, of course, the two projects of the DB server is on the same IP, that is, we are only a schema is different, How do I complete the development of the following report?
At first I directly created a dblink, but back and communicate at the same time, he thought that the impact of Dblink is too large, when two databases are not on the same server when the use of this, the current situation is best with the schema, but here or the creation of Dblink method written to facilitate the memory:
Create DATABASE link link name connect to offset database user name Identifiedby offset database user password using ' offset database IP: Port/instance name ';
Eg:create database LINKDBLINKTOAA Connect to Jason identified by abc123 using ' ServiceA ', create a connection on the line
The next is to use schema, the following statement is to use schema to do the correlation
Eg:grant Select on Jason.emp to Lucy; Authorization Query
My personal understanding of the schema is: A to see B, when A and B on the same side of the river bank (the same server), B as long as allow a to see him, when A and B is not on the same side of the bank (different server), that a to build a bridge, and also have to obtain the consent of B, That is, the user name and password of B.
The above is a personal understanding, if it is not appropriate, but also ask you to correct, learn together.
Don't forget that the table in the user being accessed is authorized by other users to access it.
How can a user in Oracle of it Ninja Turtles access other users ' tables without using a user name