CREATE SYNONYM synonym_name FOR object_name
|SYNONYM||Creates a synonym name for a table name|
|synonym_name||Name of the synonym to create|
|object_name||Name of the table or view to which the synonym name applies|
You can create synonyms for an object in the database. Synonyms can currently be created for base tables or views. The synonym name can then be used in place of the object name in queries. Note that users of the synonym name must have appropriate privileges to the base object to which the synonym applies. Synonyms are useful in that a user can access data from tables existing in other user schemas (authorization IDs) without having to specify that user's schema.
The DROP synonym command is used to remove a synonym name.
CREATE SYNONYM REPS FOR Mary.ALL_REPS_LOCATIONS