ASP. the "security" tab in the net configuration prompts "cannot connect to the SQL Server database" [Content Abstract]. This is usually because we have installed a new database and uninstalled the default sqlexpress installed in VS 2005, because the system will find sqlexpress, of course there will be problems if it cannot be found.
This is usually because we have installed a new database and uninstalled the sqlexpress installed by default in VS 2005. Because the system will find sqlexpress, it will be problematic if it cannot be found. Solution:
The instance name I used for self-installation is sqlserver2 and the machine name is a4d5df939a4f4c2.
1. Find aspnet_regsql.exe in the c: \ windows \ Microsoft. NET \ framework \ v2.0.50727directory and regenerate the aspnetdb database.
2. In VS 2005's "tool"-"option"-"database tool"-"Data Connection", change the Instance name to our Instance name.
3. In VS 2005, choose "Tools"> "connect to Database", enter the server name, and select "aspnetdb" for the database.
4. Click "Advanced..." and copy the datasource content.
5. Open IIS, click the properties of the site, click the ASP. NET tab, and change the value of localsqlserver to the string we just copied.
6. On the "authentication" tab, select "enable role management"
7. Success
When you encounter the "Stored Procedure 'dbo. aspnet_checkschemaversion'" error, pay attention to the following points:
- Whether or not aspnet_regsql has been run on the database of the website. This is a common problem. Many posts on the Internet say that starting the Wizard is just the next step. This is not comprehensive. Select the target and authentication method based on the database used by the website.
- Check the Web config of the website. If the connectionstrings section is not found, check the machine of the local machine. config (if there are two 64-bit systems) to check whether the target SQL server connected to the string matches the actual database. The default connection string is express. If you are using the development or Enterprise Edition, pay special attention to it.