Results 1 to 5 of 5
  1. #1
    Join Date
    Aug 2003
    Posts
    13

    Unanswered: What is a SYNONYM?

    Is it a table? Or a table with some special features? Why cann't I analyze a synonym table(if I can say that)?

  2. #2
    Join Date
    Aug 2003
    Location
    rotterdam
    Posts
    1

    Re: What is a SYNONYM?

    Hi crops,

    A synonym is a name for an object to make it recognisable on another way. Where is that necessary for ? you will be thinking perhaps. Well, I will give you an example of how a synonym is used.

    The user 'test' create a table 'persons' on the database. test is the owner of this table and he is able to find it by the name persons. On the database however it is registerd as test.persons. All objects owned by test fill have the prefix test. A user with al its objects is called a schema. If another user on the database wan't to access the table persons he will not find it by just using persons. If he has the rights he can access it by test.persons. What also is possible is to make a synonym for the table. The other username is test2. Test can make a synonym test2.persons for the table persons. If that synonym excists test2 will be able to access the persons table by just using persons as table name.

    There is lots behind this principle on oracle all having to do with access rights and the way you make the objects available to other users.

    succes,
    Joost

  3. #3
    Join Date
    Aug 2003
    Posts
    13
    Thanks a lot, joostvc.

    as you said, a synonym is something like a friend function in C++. You can not access it in most cases unless you become a friend of mine.

    I can not analyze the synonym because the owner didn't give me enough privilege ---- Is this right?

  4. #4
    Join Date
    Aug 2003
    Location
    Bremen, Northern Germany, Central Europe
    Posts
    1

    no analyze on synonyms

    Hi crops,

    there are possibly two reasons why you cannot analyze the synonym.

    1.

    A SYNONYM ist something like a pointer or a link.
    The syntax of the ANALYZE-command ist
    ANALYZE [ TABLE | INDEX | CLUSTER ].
    There is no ANALYZE SYNONYM, and I think, the SYNONYM does not give the command through to the original table.
    You must analyze the physical table (the original table).

    2.

    Having not the privileges is the secon reason.

    Hth
    Johannes

  5. #5
    Join Date
    Aug 2003
    Posts
    13
    Quite reasonalbe. Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •