locked
Error when wepart trying to access the database RRS feed

  • Question

  • Helo all,

    I am getting following error when my custom webpart in sharepoint is trying to access the database...

    The SELECT permission was denied on the object 'Emp', database 'Webpart', schema 'dbo'.The IListSource does not contain any data sources.

      Any suggestions
    Saturday, July 17, 2010 8:11 AM

Answers


  • GRANT ALTER ON SCHEMA::dbo TO [IISUser]

    GRANT EXEC ON some_sp TO IISUser-- Grant permission on a single procedure.
    GRANT EXEC ON SCHEMA::dbo TO IISUser-- Grant perpmission on all procedures in
                                          the dbo schema
    GRANT EXEC TO IISUser-- Grant EXEC permission all procedures in the database.


    Best Regards, Uri Dimant SQL Server MVP http://dimantdatabasesolutions.blogspot.com/ http://sqlblog.com/blogs/uri_dimant/
    Sunday, July 18, 2010 7:56 AM

All replies

  • Hi,

    You need to assign permission to the IIS WP to the table or the schema. Here is an exaple: Change IISUser to your IIS WP user.

    GRANT SELECT ON SCHEMA::dbo TO [IISUser]
    

    I hope it helps.

    J.

     


    There are 10 type of people. Those who understand binary and those who do not.
    Saturday, July 17, 2010 8:42 AM

  • GRANT ALTER ON SCHEMA::dbo TO [IISUser]

    GRANT EXEC ON some_sp TO IISUser-- Grant permission on a single procedure.
    GRANT EXEC ON SCHEMA::dbo TO IISUser-- Grant perpmission on all procedures in
                                          the dbo schema
    GRANT EXEC TO IISUser-- Grant EXEC permission all procedures in the database.


    Best Regards, Uri Dimant SQL Server MVP http://dimantdatabasesolutions.blogspot.com/ http://sqlblog.com/blogs/uri_dimant/
    Sunday, July 18, 2010 7:56 AM