Problem with aspnet_regsql.exe - asp.net

i wrote a website with asp.net 4 and sql server 2008. But my host sql version is 2005 so i get script from my database in sqlserver 2008 and convert it to 2005. Then i import .sql file that is exported from 2008 iin sqlserver 2005 and retrieve it. Then i make a back up with sqlserver 2005 and upload it on my host. Now i have one problem:
I used aspnet_regsql.exe to create the database schema.
But when i want to login to my website it throws following error:
The 'System.Web.Security.SqlMembershipProvider' requires a database
schema compatible with schema version '1'. However, the current
database schema is not compatible with this version. You may need to
either install a compatible schema with aspnet_regsql.exe (available
in the framework installation directory), or upgrade the provider to a
newer version.
What is the problem?

Which version of ASP.NET is your published website using? It looks like it might be different than what you're using in development.
The version info is configured on a per-AppPool basis in IIS.

Related

Can't see teradata data provider in visual studio 2013

I've just installed visual studio 2013 and tried to setup Entity framework to access an teradata database.
I click on new ADO.NET entity model, then Generate from database, but on the data connection screen when I click "New Connection" I don't get teradata appearing the list of datasources. I only get two SQL server options.
Do I need to install something extra to get this to work?
I have installed teradata latest version from there website.

Install Oracle Database Extensions for .NET into VS2013

How to install Oracle Database Extensions for .NET into VS2013.
32-bit Oracle Data Access Components (ODAC)
with Oracle Developer Tools for Visual Studio
Everytime I run this installer, it is always exclude Oracle Database Extensions for .NET. There is a reminder of for upgrade only in the description of the package installer.
Oracle Database Extensions for .NET 4 12.1.0.1.0 -- for upgrade only
Oracle Database Extensions for .NET 2.0 12.1.0.1.0 -- for upgrade only
So where should I get the installer for Oracle Database Extensions? Currently I using VS2013 Professional and Oracle database server 11g 64 bits.
I need that because of Developing and Deploying a .NET Stored Procedure using Oracle Deployment Wizard.
Developing and Deploying a .NET Stored Procedure
Inside this website, you can see the tutorial for VS2010 version.
Additional: I have to use Oracle 12c client 32bits because of VS2013 and Entity Framework.
Additional: I have ttied 64 bits, but my VS2013 still doesn't have Deploy option
Well, this is guesswork:
Try installing Oracle 10g ODAC and Oracle Developer Tools for Visual Studio .NET (very bottom of the downloads page) first, and then install the latest for upgrade only distribution.
Okay, here's an excerpt from Oracle Database Extensions for .NET:
This product is included with the Oracle Database on Windows installation. Further upgrades are installed as part of the Oracle Database Access Components (ODAC) releases, however Oracle Database Extensions for .NET must first be installed and configured before it can be upgraded.
Also, I found Oracle® Database Extensions for .NET Developer's Guide 12c Release 1 (12.1) for Microsoft Windows. In it's Installation and Configuration > Installation section:
Before the first use of Oracle Database Extensions for .NET, do the following:
Install Oracle Database 12c and either allow the installer to create the database for you, or install the database software only and use Database Configuration Assistant to create a database afterwards.
After installation and database creation, execute the following to enable Oracle Database Extensions for .NET.
chopt enable ode_net
Execute the following to create the Oracle Database Extensions for .NET windows service.
oraclrctl -new
Bottom line: You have to install Oracle Database 12c to enjoy Oracle Database Extensions for .NET. It is meant to be a service running along with the database server, not in the client.

ASP.NET Error with Database

I have been learning ASP.NET and building a little customer portal. I used the built in CreateUserWizard. I wanted to look inside the ASPNETDB.MDF file to see how it was storing the users and maybe add some rows of my own. I opened the file in SQL Server Management Studio and viewed the file. I closed it with out saving.
Now when I try to run the program I get this new error:
The database 'C:\PROJECTS\PORTAL\PORTAL\APP_DATA\ASPNETDB.MDF' cannot be opened because it is version 706. This server supports version 662 and earlier. A downgrade path is not supported.
So I assume opening the project in SQL Server it upgraded the version to 706, How can I either delete this database and create a new one or change the version of the database to an support version.
Thanks
The following blog entry will help you
http://conceptdev.blogspot.com/2009/04/mdf-cannot-be-opened-because-it-is.html
As soon as you attached it to SQL Server 2012, the database was upgraded to version 706. As the error message suggests, there is no way to downgrade the file back to version 662 (SQL Server 2008 R2).
You can run the script found in your Visual Studio folder -
[drive:]\%windir%\Microsoft.NET\Framework\version\asp_regsql.
It'll display a UI for you to select the server to install a new copy on. Here's a MSDN article about it.

MDF Cannot Connect from Visual Studio

I am getting this error and I have SQL Server 2012 installed anyone know what's wrong? I am trying to attach a database file into my Visual Studio 2010.
The database 'X' cannot be opened because it is version 661. This
server supports version 655 and earlier. A downgrade path is not
supported.
Could not open new database 'X'. CREATE DATABASE is aborted.
An attempt to attach an auto-named database for file X failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.
The database file was created and/or attached on a SQL Server instance that was of a newer version than the one you have. If you bring your local instance up-to-date to a newer build, then you should be okay.
More specifically - version 661 is SQL Server 2008 R2. The instance you are attaching (651) to is SQL Server 2008 RTM or SP1. Be sure it is using SQL Server 2012 instance instead of perhaps a local SQL Express instance.
See here:
http://www.sqlskills.com/blogs/paul/sql-server-2008-r2-bumps-the-database-version/
Turns out the problem is with regard to an Express Edition. I cannot use the full version because the mdf file I'm binding requires user instance which is only supported by Express Editions. I downloaded the SQL 2012 Express from this https://www.microsoft.com/betaexperience/pd/SQLEXPWT/enus/default.aspx which allows for LocalDB and all the problems go away.

Unable to find the requested .Net Framework Data Provider. It may not be installed

We are getting this error when updating site on new server. We are using mysql with asp.net project in visual studio 2010.
Unable to find the requested .Net Framework Data Provider. It may not be installed
Thanks.
The MySql provider specified in your connection string is not installed on the server. Install it. It'll be whatever is installed on your development machine.
For a better answer, please post the part of your connection string that shows which provider/version to use.

Resources