Can ASP.NET 2.0 Use SQLServer 2000 For Membership Function

D

Dan Sikorsky

Can I use SQLServer 2000 with ASP.NET 2.0 instead of SQLServer 2005, and use
the .Net 2.0 Membership functionality?

I've setup my Login page, controls, etc., and now it's time to use the Web
Site Administration Tool (WAT) but it won't sense my SQLServer 2000
database.
 
G

Guest

I had the same problem, but found the solution.

I'm running 2k5 Team Edition, with a sql 2000 database in the back and IE7
beta 2 in the front. I made two mistakes. The first mistake was using the
IE7 beta. It would time out rather than show me the helpful error messages
that the Web App Admin Tool shows when it cannot connect to the database.
Uninstalling IE7 allowed me to troubleshoot these errors. The second mistake
was not installing SQL 2k5 Express. Why is that a mistake? Because the
default provider is configured for sql 2k5 and is incompatible with sql 2k.
It was also a mistake because it is near friggin impossible to add an effing
provider. If you know how to add a new provider that supports sql 2k, then
you aren't reading this. Anyhow, to get ASPNET 2.0 working with your current
instance of sql 2000, you need to first get your sql server configured
correctly. To do this, do the aspnet_regsql.exe thing. You'll need to run
the correct one, which is accessible when you run the "Visual Studio 2005
command prompt". Its under Proggy files, Visual studio 2005, Visual studio
tools. Once you've done that, you have to trick the Web App Admin tool to
use this database rather than the nonexistant 2k5 express database (how
incredibly goddamn stupid is that?). Create a connection string to your Sql
2000 database (make sure it works!), and add the following section to your
website's web.config file:

<connectionStrings>
<remove name="LocalSqlServer"/>
<add name="LocalSqlServer" connectionString="PUT YOUR CONNECTION STRING
HERE!" />
</connectionStrings>

Notice that you nuke the connection string that the default provider uses,
then replace it with your connection string. This section should be added
right after the <configuration xmlns="...> line at the top of web.config.
Once you've done this, save web.config and attempt to use the Web Application
Tool again. It should work! I'd like to thank Microsoft for giving us all
these great new features in 2.0, and damn them to hell for turning web apps
from just another application (add a DLL project to your web app solution?
No problem! Namespaces in your classes? No problem!) into some weird
bastardized child-monster with app_code directories and crippled integration
into the IDE (I have to use a TOOL in a WEBPAGE to change settings in my
APPLICATION???) and solutions that are projects...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top