Delete user from aspnet_users table
-
hi all i have shown all of my existing users in a griedview from aspnet_users table. now i want to delete user on delete command but on when i tried to do this i got error. plz guide me....
-
Please post the error details and the code segment where the error is generated.
Cheers!! Brij
I got following error as soon as tried to delete a user...
The DELETE statement conflicted with the REFERENCE constraint
"FK__aspnet_Me__UserI__1B0907CE".
The conflict occurred in database "Sitname",
table "dbo.aspnet_Membership", column 'UserId'.
The statement has been terminated. -
I got following error as soon as tried to delete a user...
The DELETE statement conflicted with the REFERENCE constraint
"FK__aspnet_Me__UserI__1B0907CE".
The conflict occurred in database "Sitname",
table "dbo.aspnet_Membership", column 'UserId'.
The statement has been terminated.You can not delete a user just from deleting the row from aspnet_users table,Because there is a tight assoiation with other tables.First you need to understand the apnet membership schema,then you will be able to know how to a user from database directly. Or you can use the inbuild function of aspnet membership api to delete a user from application. But if you want to delete from database directly, it will better if you ask in database forum.
Cheers!! Brij
-
You can not delete a user just from deleting the row from aspnet_users table,Because there is a tight assoiation with other tables.First you need to understand the apnet membership schema,then you will be able to know how to a user from database directly. Or you can use the inbuild function of aspnet membership api to delete a user from application. But if you want to delete from database directly, it will better if you ask in database forum.
Cheers!! Brij