ASP.Net Membership.DeleteUser

前端 未结 7 2039
感情败类
感情败类 2021-02-06 03:19

In testing, the user on a db i\'ve used was a big jefe. In production, he only has Execute.

When I called,

Membership.DeleteUser(user)

7条回答
  •  [愿得一人]
    2021-02-06 03:59

    I solved this by removing the line in the proc which checks for the view. I don't have the any asp membership views and haven't needed them anywhere, so it seems pretty pointless to create the view just so that line of code can return true - the proc doesn't actually use the view. Perhaps if you use more features of the membership objects you might need the view for something else. Either way checking for the view's existence seems an odd way for the proc to decide whether the aspnet_membership table has a row it needs to delete.

    IF ((@TablesToDeleteFrom & 1) <> 0 
        )
        --AND
        --   (EXISTS (SELECT name FROM sysobjects WHERE (name = N'vw_aspnet_MembershipUsers') AND (type = 'V'))))
    

提交回复
热议问题