Home Dashboard Directory Help
Search

.Net 4 ASPState Session SQL script files bug by gindi


Status: 

Closed
 as Not Reproducible Help for as Not Reproducible


2
0
Sign in
to vote
Type: Bug
ID: 620681
Opened: 11/10/2010 1:40:09 PM
Access Restriction: Public
1
Workaround(s)
view
1
User(s) can reproduce this bug

Description

Run aspnet_regsql.exe using the wizard to set up your ASPState database for .net 4. Then try to run a website against it...you get the following error:

'System.Web.HttpException: Unable to use SQL Server because ASP.NET version 2.0 Session State is not installed on the SQL server. Please install ASP.NET Session State SQL Server version 2.0 or above.'

The script files in C:\Windows\Microsoft.NET\Framework64\v4.0.30319\ contain an error and the database is not properly set up. We found the script file problem which makes the script fail due to the double quotes around the 2:

CREATE PROCEDURE [dbo].[TempGetVersion]
@ver     char(10) OUTPUT
AS    
     set nocount on
         SELECT @ver = "2"
RETURN 0

The following blog led us down the correct path at finding the problem. The last comment is from us showing our temporary fix around the problem. We wound up correcting the script (putting single quotes around the 2), running it manually, so we could get it working.

http://sqlblog.com/blogs/aaron_bertrand/archive/2010/09/10/a-quick-workaround-to-a-misleading-aspstate-problem.aspx






Details
Sign in to post a comment.
Posted by Microsoft on 11/16/2010 at 4:55 PM
Closing out per customer comments.
Posted by gindi on 11/11/2010 at 8:53 AM
We read more about the wizard and found that it doesn't install session state and you must run it from command line. We also looked at the scripts closer and saw that Set Quoted_Identifier Off is at the top. So this is not a bug and works fine when ran from the command line.
Posted by Microsoft on 11/10/2010 at 2:23 PM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(http://support.microsoft.com)
Sign in to post a workaround.
Posted by gindi on 11/10/2010 at 1:47 PM
Correct the script by putting a single quote around the 2 and run the script manually.