Total Pageviews

2016/02/24

[Oracle] How to grant privilege and create synonym in Oracle

If I would like to grant two views, dbm200va and dbm400va, to another database user. How do to it?


Syntax for tables/views is as bellows:
GRANT privilege-type ON [TABLE] { table-Name | view-Name } TO grantees



In addition to grant privileges by ap_dbm, ap_psr also need to create synonym on its side.
Create synonym syntax is as following:
CREATE [PUBLIC] SYNONYM [schema .] synonym FOR [schema .] object [@ dblink];



Reference
  1. grant privilege: http://docs.oracle.com/javadb/10.8.1.2/ref/rrefsqljgrant.html
  2. create synonym : http://docs.oracle.com/cd/B19306_01/server.102/b14200/statements_7001.htm

No comments: