Create a synonym for Oracle

Source: Internet
Author: User

after receiving instructions from the user today, you need to create a table in the database. After the script is written, the user is successfully executed, but the user is found to be using the error user1, user2 should be used.

Delete the original table, log on to user2 again, and execute the script. Everything is OK.

the user user1 cannot access the result. Suddenly, the user is not authorized, and the PL/SQL authorization fails, only scripts can be used for execution

execution:

grant select, insert, update on table name to user name;

users using user1 still cannot access the table directly. If you select * From user2. the table name is OK, ask an expert, create a synonym in user1

Create a synonym statement in Oracle:
Create synonym table_name for user2.table _ name;

although I have been busy for one afternoon, I have learned new things. What I learned is that it is worth your attention ~~~

good knowledge, good experience, and sharing can save a lot of time ~~~

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.