Problem operation:
1. Click "ASP. NET configuration" in Solution Explorer to enter the membership user role configuration. If the configuration fails, the following error is reported;
2. An error is reported when the static method of membership is called;
Error: "system. Web. Security. sqlmembershipprovider" requires a database architecture compatible with architecture version 1. However, the current database architecture is not compatible with this version. You may need to use aspnet_regsql.exe (provided in the Framework installation directory) to install a compatible architecture or upgrade the provider to a newer version.
Note: An unhandled exception occurs during the execution of the current Web request. Check the stack trace information for details about the error and the source of the error in the code.
Solution: execute the following SQL statement in the database that uses membership (at least I solve this problem)
/*Insert aspnet_SchemaVersions*/INSERT INTO [dbo].[aspnet_SchemaVersions] ([Feature] ,[CompatibleSchemaVersion] ,[IsCurrentVersion]) VALUES ('common','1',1)INSERT INTO [dbo].[aspnet_SchemaVersions] ([Feature] ,[CompatibleSchemaVersion] ,[IsCurrentVersion]) VALUES ('health monitoring','1', 1);INSERT INTO [dbo].[aspnet_SchemaVersions] ([Feature] ,[CompatibleSchemaVersion] ,[IsCurrentVersion]) VALUES ('membership', '1', 1) INSERT INTO [dbo].[aspnet_SchemaVersions] ([Feature] ,[CompatibleSchemaVersion] ,[IsCurrentVersion]) VALUES ('personalization','1', 1) INSERT INTO [dbo].[aspnet_SchemaVersions] ([Feature] ,[CompatibleSchemaVersion] ,[IsCurrentVersion]) VALUES ('profile','1', 1)INSERT INTO [dbo].[aspnet_SchemaVersions] ([Feature] ,[CompatibleSchemaVersion] ,[IsCurrentVersion]) VALUES ('role manager','1', 1)