Sign up ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

When I try to GRANT EXECUTE ON SP_NAME TO [DOMAIN\USER_NAME] on my database, I'm getting the error message below:

Msg 8115, Level 16, State 1, Procedure grant_safety, Line 5
Arithmetic overflow error converting IDENTITY to data type smallint.
Arithmetic overflow occurred.

This is happening in any procedure where I try to GRANT EXECUTE permissions; I have tried to grant to other users as well, but same error.

   SELECT 1  
share|improve this question

closed as off-topic by Paul White, Mark Storey-Smith, RolandoMySQLDBA, Shawn Melton, RLF Dec 22 '14 at 15:37

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Too localized - this could be because your code has a typo, basic error, or is not relevant to most of our audience. Consider revising your question so that it appeals to a broader audience. As it stands, the question is unlikely to help other users (regarding typo questions, see this meta question for background)." – Paul White, Mark Storey-Smith, RolandoMySQLDBA, Shawn Melton, RLF
If this question can be reworded to fit the rules in the help center, please edit the question.

Does each error indicate "Line 5"? –  Shawn Melton Nov 9 '13 at 3:50
Yes, each error indicated "Line 5" –  Amam Nov 9 '13 at 4:25
So the GRANT EXECUTE command is line 5? Have you tried the syntax noted in MSDN: GRANT EXECUTE ON OBJECT::dbo.myproc TO myUser? –  Shawn Melton Nov 9 '13 at 7:08
Could you add the stored proc definition to your question, please? –  Max Vernon Nov 9 '13 at 15:49
Could there be a DDL database trigger or server level trigger setup that is logging or blocking grants by design using a proc named grant_safety? Keep in mind, if you are not a sysadmin then you might not be able to see the grant_safety proc when looking in the database. –  BateTech Feb 11 '14 at 3:40

1 Answer 1

Try putting a GO on a newline between your procedure DDL and your grant statement and after the grant.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.