Synonym (database)

In databases, a synonym is an alias or alternate name for a table, view, sequence, or other schema object.

Synonyms are very powerful from the point of view of allowing users access to objects that do not lie within their schema.

To be able to perform those operations, a user needs specific privileges for the underlying object, either directly or through roles from the application owner.

A private synonym is a synonym within a database schema that a developer typically uses to mask the true name of a table, view stored procedure, or other database object in an application schema.

The following example shows how to create a private synonym called addresses for the locations table.