Having problems restoring a database on SQL Server 2008 - asp.net

I am dealing with a weird problem in SQL Server 2008.
I previously had SQL Server 2005 installed on my local machine.
I have a backup of a SQL Server 2008 which has to be worked upon locally and then restored to the original database (work involves use of ad-hoc queries which is disabled on my server since it is hosted with an ISP.)
Problem:
The SQL Server 2008 is giving me the following error.
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
The media family on device 'D:\Data\F1\purt144_634889883032976839.bak' is incorrectly formed. SQL Server cannot process this media family.
RESTORE HEADERONLY is terminating abnormally. (Microsoft SQL Server, Error: 3241)
Questions:
Can 2 or more versions of SQL Server co-exist on same machine? If yes why is the server instance showing version no 09.XXX (in the right hand section for SQL Server Management Studio 2008) version for SQL Server 2008 being 10.XX.
What could possibly be the problem apart from database being corrupted or backward compatibility issues?
Thanks.

Yes, you can have many instances of the same or of different versions of SQL Server installed on the same machine; so you can have one or more instances of SQL Server 2005 along with one or more instances of SQL Server 2008 (or of any other versions of SQL Server).
0 (zero) or one of these instances will be the default (or unnamed) instance and all the others will be named instances.
When upgrading from SQL Server 2005 to SQL Server 2008, depending on the options chosen, an existing instance (possibly but not necessarily the default instance if it exists) could have been upgraded from SQL Server 2005 to SQL Server 2008 or a brand new instance of SQL Server 2008 could have been installed alongside.
You should check the list of services to see the list of instances that you have on your machine. The SQL Server Configuration Manager that came with SQL Server 2008 will show you that under the SQL Server Services node.
The one with the name MSSQLSERVER will be the default or unnamed instance because you can connect to it without specifying its name. All the others will be named instances.

Related

Upgrade SSO database, can we avoid reconfiguration?

We are on BizTalk 2013 Enterprise, we just noticed that the SSO database was accidentally deployed to SQL Server 2008 instead of SQL 2012 (where all other databases is), question is can we just take the database from SQL 2008 restore it on SQL 2012 and update BizTalk management database to point there instead of reconfigure BizTalk, redeploy and risk the application outage? Thanks
Yes.
You would follow the procedures documented here: Moving BizTalk Server Databases
In your case, you would only move the SSODB and follow the restore instructions for SSODB only.

SQL Server 2008 R2 Express ODBC - Not showing database

Created a new database called Test, when I try to connect to the SQL Server database via Excel I can't see the Test database which was created, I can only see master, msdb, tempdb.
I'm running SQL Server 2008 R2 Express.
I am new to Server Management, requesting some help so I can consume the data in an Excel sheet.
Got it fixed.
MS SQL was installed on a differnet domain and had windows authenticaion
When accessing from excel there was no option to choose windows authentication using a different domain.
Solution - Created a MS SQL User ID and gave access to the required database

VWD can't create SQL Server database

When I attempt to add a SQL Server database to a website project (via add new items), I get the following error:
"Connections to SQL Server database
files (.mdf) require SQL Server 2005
Express or SQL Server 2008 Express to
be installed and running on the local
computer. The current version can be
downloaded from..."
This is despite having installed SQL SErver Express 2008 - and seeing it running under services.
A number of other instances of SQL have been on the machine in the past although they have been uninstalled.
I have tried reinstalling SQL & VWD several times to no avail.
Check the "SQL Server Instance Name" which is setup in:
Tools --> Options --> Database Tools --> DataConnections
Verify that the instance name matches your SQL08 instance.

SQL Server 2008 user instance database creation failure within an asp.net project

I'm trying to create a database within the app_data folder of an asp.net mvc project using the IDE, but i am getting a "Required Components Missing" message indicating "Connections to SQL Server files (*.mdf) requireSQL Express 2005 ....."
I am using
- Windows 7 Enterprise
- VS2008 Team System SP1
- SQL Server 2008 Developer Edition SP1
I have altered the database connection to use the default instance by setting to blank using
Tools -> Options -> Database Tools -> Data Connection : SQL Server Instance Name
I also note from the SQL Server Books Online that the user instance feature will be removed in the future, but for now it suits my effort in developing an application where a number of people are working on the project.
Has anyone managed to create a database in the same manner?
It appears Nerd Dinner has done so
The attached user-instance database in the App_Data will work only with a SQL Server Express edition - 2005 or 2008.
It does not work with a full SQL Server edition, like Web, Workgroup, Standard, Enterprise or Developer. It does not - no way - no trick to make it work - does not - period.
If you want to use that mechanism of attaching a user instance database in your App_Data folder, you must use SQL Server 2005/2008 Express.

ASP.NET cannot connect to 64-bit Sql Server 2008

We have an ASP.NET application written in Visual Studio 2003 (c#) using SQL Server 2000 as database. It’s an old web application that our clients have been using for 4+ years.
Now, we needed to upgrade the application to work on Windows Server 2008 using SQL Server 2008, both 64bit, both on the same machine. So we ported the application to Visual Studio 2008, made some needed modifications and successfully installed the application on Windows Server 2008 with database still being the old SQL Server 2000. Everything worked fine. But as soon as I modified the connection string to work with the new SQL Server 2008 64bit, it stopped working. Basically the web browser just shows – The webpage cannot be displayed; no error messages whatsoever.
I monitored the processess and event log - basically it seems that asp.net worker process is generating errors until it stops working. And I can’t figure out why. All should be fine on SQL Server 2008 side, all protocols enabled, even disabled firewall; i can connect to the instance using Management studio from the same server (64bit) and from other development machines (64bit/32bit).
Then i tried using the web application from my development machine (still Vistual Studio 2003 one, i.e. 32 bit with ASP.NET 1.1) and connect to the new SQL Server 2008 and i got „Server application unavailable“ error. Same thing happens, worker process is generating errors until it stops working.
I used IIS Diagnostic Tool to debug the moment the error occurs – all i got was basically unlimited numbers of „First chance“ exceptions (problems with msvcr80.dll, mscorwks.dll). If I limited the number of those, I also managed to get „Kernel32!TerminateProcess“ exception, which after analysis stated that it didn’t detect any problems with that; only one time i got the warning, describing that 1 client connection was executing for more than 90 seconds.
I dont think the problem is on the 64bit Windows server 2008 or SQL server 2008 side, since when, just for checking, we used Sharepoint application with the new SQL Server 2008 as database, it connected just fine.
So what am I missing with our ASP.NET application configuration/development that it cannot connect to 64 bit Sql server 2008?
Thanks and regards,
Martin.
This sounds like a configuration problem, probably a permissions problem. Your Sql Server is on a different box than the your web server? If so I would look at what user your web site is running under. Make sure that user has access to the Sql Server.
If your user does have access make sure it has access to travel the wire to your SQL Server. Try to connect to the SQL Server via Sql Management Studio with the user's credentials.

Resources