Home » RDBMS Server » Server Administration » diff between view and synonym
diff between view and synonym [message #54313] Mon, 11 November 2002 06:16 Go to next message
Gurdeep Singh
Messages: 64
Registered: October 2002
Member
Hi Evrybody
Please tell me the difference between view and synonym. What is the need of synonym. Is it occupy disk space.
Re: diff between view and synonym [message #54314 is a reply to message #54313] Mon, 11 November 2002 06:24 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10708
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
VIEW:

1. is a restricted / unrestricted portion or whole
   table.
2. View is defined using a query.
   every time, u call the view, the query is executed.
   does not require any storage.
   you can have a view on a table or view.
   view behaves exactly the same as a table.

SYNONYM:

1. another Name for a table, which may be public ( access
   to all or private.

Re: diff between view and synonym [message #54329 is a reply to message #54313] Mon, 11 November 2002 16:47 Go to previous message
Trifon Anguelov
Messages: 514
Registered: June 2002
Senior Member
The synonym allows the schema.object syntax in a query to be substituted to only object specification. It does shield the owner of the object and the users doesn't have to know in each schema the real object is't. You can move the object from schema to schema without to change your application code, export from user to another user too.

All you have to do is to re-create the public synonym.

And yes, it does occupy one row in data dictionary table, nothing else.

Hope that helps,

clio_usa
OCP - DBA

Visit our Web site

Previous Topic: Re: ocp *.* - dumps,braindumps,kits,cbt,tbt,sts......
Next Topic: Difference between 8i and 9I
Goto Forum:
  


Current Time: Fri Dec 27 16:51:00 CST 2024