DBAsupport.com Forums - Powered by vBulletin
Results 1 to 5 of 5

Thread: Access sequences

  1. #1
    Join Date
    Aug 2002
    Posts
    115

    Access sequences

    Hi,

    I have a sequence in schema "A".

    Now I want to access this sequence from schema "B" through a procedure.

    I ve given the select grant for this sequence..but still I am not able to see that sequence.

    funny part is...few sequnecs I am able to see...its like..out of 10 i can see 6..rest 4 it gives me this error

    ORA-02289: sequence does not exist

    can anyone please tell me if Ive missed any grants?
    Thanks
    Sam

  2. #2
    Join Date
    Nov 2006
    Location
    Sofia
    Posts
    630
    Please note that if your procedure is created to use owneres rights, it does not sees the rights granted via role. So if you gave grant select on the sequence to a role and then grant the role to the user, owning the procedure, the procedure will still not be able to see the sequence. That's pretty much common mistake

    Regards
    Boris

  3. #3
    Join Date
    Mar 2007
    Location
    Ft. Lauderdale, FL
    Posts
    3,555
    Assuming you have your privileges right...

    Have you fully qualified the sequence name?... like schema_name.sequence_name?

    OR

    Have you created a public synonym for your sequence?
    Pablo (Paul) Berzukov

    Author of Understanding Database Administration available at amazon and other bookstores.

    Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.

  4. #4
    Join Date
    Aug 2002
    Posts
    115
    got the error fixed...

    we had given the scehma name in double quotes..."schemaname".sequencename...

    dont know why..but oracle was acting case sensitive here!!!

    thanks
    Sam

  5. #5
    Join Date
    Mar 2007
    Location
    Ft. Lauderdale, FL
    Posts
    3,555
    Quote Originally Posted by aspdba
    dont know why..but oracle was acting case sensitive here!!!
    ... perhaps 'cause of you have enclosed the schema_name in between quotes?

    Anyway, thank you for being honest and telling us what really happened
    Pablo (Paul) Berzukov

    Author of Understanding Database Administration available at amazon and other bookstores.

    Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.

Posting Permissions

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


Click Here to Expand Forum to Full Width