Having trouble migrating from sql 2000 to sql 2008 - sql-server

I have an old 32-bit application sitting on a sql server 2000 personal edition windows NT 6.0 service pack 2.
I am performing a side-by-side migration
I was given a windows 2016 x64.
I installed SQL Server 2008 developer edition x86
I backed-up and restored the necessary databases, changed compatibility level, move logins and permissions, move over necessary extended stored procedures.
ISSUE: The application throws an error when trying to connect. 'Could not load the DLL C:\Program Files (x86)...applicationspecified.dll, or one of the DLLs it references. Reason: 126(The specified module could not be found.)'
I did check to confirm the path is correct.
I used dependency walker to see if there were any missing DLLs
EDIT: The app was installed on the new windows server (2016), opening the app while on windows 2016 against old database/sql2000 works fine. Opening the app against the new databases/sql2008 fails.

Related

SQL Server LocalDb And Compatibility Issues Between Workstations

I have both a laptop and desktop computer for development on both of which I have installed Visual Studio 2015 Express for Web. I'm developing an ASP.Net MVC application with Entity Framework code-first.
On the laptop, I was able to add a SQL Server LocalDb database file to the App_Data folder, however when trying to open the database on the desktop machine (with the same version of Express 2015 for Web installed - from the same installer), I get error messages saying something along the lines of:
The database file you are attempting to connect to is not compatible with the current instance of SQL Server. To continue, you must upgrade this database file...
Having been through this loop several times with endless issues relating to compatibility of LocalDb databases between workstations, I'm getting a bit fed up. Every time I've had compatibility issues between machines whereby I've upgraded the database only for the other workstation not to be compatible with that version.
My question is: is it worth persisting with LocalDb or should I just move the database across to SQL Server Express and be done with it? I like the idea of LocalDb as I can keep the database in the solution.

Local SQL Server 2008 R2 database not accessible on Windows 10

I've inherited the job of maintaining an application which uses a local SQL Server 2008 R2 SP2 Express database as a back-end. I successfully installed the application some months back after upgrading to Windows 10 so that I could start testing and development, but after reformatting recently, I've been unable to get the database running. I'm using the exact same installer, and so far as I can tell, everything else configuration-wise is the same, with the exception that I'm now on a newer W10 insider build.
The application installer installs SQL Server 2008 R2 with the following parameters:
/TCPENABLED=1 /ACTION="INSTALL" /SQLSVCSTARTUPTYPE="automatic"
/SECURITYMODE="SQL" /SAPWD="password" /INSTANCENAME="app"
/FEATURES=SQLENGINE,REPLICATION /BROWSERSVCSTARTUPTYPE="Automatic"
/SQLSVCACCOUNT="NT AUTHORITY\NETWORK SERVICE" /IACCEPTSQLSERVERLICENSETERMS
/INDICATEPROGRESS /QS
The installer is built using Advanced Installer, and is configured to run a database setup script after installation has completed, but when it reaches this step the database times out and the install fails. To test the database I tried using a UDL file, and though the database itself is visible, when I attempt to test the connection I get
"Test connection failed because of an error in initializing provider.
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or
access denied."
I've tried absolutely everything I can think of to fix this problem. I've removed all traces of every version of SQL Server from my computer, purged the registry of any remaining keys, and deleted any remaining directories. I've checked and restarted all SQL services, tried different SQL service accounts, different versions of the SQL installer, ran the installer(s) as an administrator, ran them in compatibility mode, and checked log files. I haven't found anything helpful on StackOverflow or on Advanced Installer's forums. Nothing's worked, and I'm completely out of ideas at this point.
According the MS only SQL server 2012 SP2 and up are compatible with Windows 10.
You might try this instruction to install SQL express 2008 R2, but I never tried it: https://www.youtube.com/watch?v=DUCbvfFEO34

Sql Server 2008 installation error : Attempt to perform an unauthorized operation

I had sql server 2008 r2 express edition in my PC .But i unistalled it ,In order to install Sql server 2008 Enterprise edition trial version in my PC.
But some features in sql server 2008 showing "attempt to perform an unauthorized operation" error during installation process.
My operating system is windows 7 home basic 64 bit.
these are the feature which are showing error while installation:
sql server database engine service
sql server replication
sql server analysis services
please help me with this issue
Here's a couple things to try from people who have had similar problems:
Check: %\Microsoft SQL Server\100\Setup Bootstrap\Log\SystemConfigurationCheck_Report.htm
Copy installation files to disk and run from there.
Run setup as administrator.
Create a new local administrator account and use that to run the installation.
When error occurs, dont exit installation, run process monitor trace, click retry for installation, stop trace, locate registry key where where access denied is, give your account temporary full control on that key, retry again.
Use the slipstream procedure to update SQL Server 2008
This method allows you to update the entire product when you run the SQL Server 2008 Setup program after following one of the following procedures:
Procedure 1: Basic slipstream steps
Follow the following steps to create a slipstream drop that you can use for installing the original media and a service pack at the same time.
Install the following prerequisites for SQL Server 2008.
.NET Framework 2.0 SP2 for SQL Server 2008 Express Edition
You can obtain the .NET Framework 2.0 SP2 from the following Web site in Microsoft Download Center:
http://www.microsoft.com/downloads/details.aspx?FamilyID=5b2c0358-915b-4eb5-9b1d-10e506da9d0f&displaylang=en
.NET Framework 3.5 SP1 for other editions
To download and install the .NET Framework 3.5 SP1, visit the following Microsoft Web site:
http://go.microsoft.com/fwlink/?LinkID=120550
Windows Installer 4.5
To download and install Windows Installer 4.5, visit the following Microsoft Web site:
http://go.microsoft.com/fwlink/?LinkID=49112
Download the latest service pack package that matches you system architecture. For example download the x64 package of SQL Server 2008 Service Pack 1 if your system is an x64-based system.
Extract the service pack by running the following command:
SQLServer2008SP1-KB968369-x64-ENU.exe /x:C:\SP1
Run the service pack to install Setup files on the computer. You will receive a Setup Support Files dialog box if the Setup support files have not been installed. You can also run the following file to install the setup support files:
C:\SP1\x64\setup\1033\sqlsupport.msi
Finally,
run the Setup.exe file from the SQL Server 2008 source media by specifying the /PCUSource parameter. For example:
Setup.exe /PCUSource=C:\SP1
I have been googling for this issue a lot but there were no solution working for me. atlast , I formatted my system for a fresh install which worked fr me.
The solution is simple.
1 - Install ONLY "Sql Server Database Engine"
2 - Start installation again and add any other features to your instance
P.S. No need to run as Admin or in Windows 7 compat-mode (if you are installing on 8 or 10)
In my Case, creating an Administrator Windows Account and installing SQL Server worked!
Also you can simply activate the built-in windows Administrator Account by running the "net user administrator /active:yes" command in command prompt(Admin Mode), then log in as Administrator. Now You can Install SQL Server without problem!
Finally I should say that you can use SQL Server from your own normal windows account after Installation and I recommend deactivating Administrator Account by "net user administrator /active:no"

Deploying SQL server with VS 2012 application

I'm working on a winform application using VS2012 (.NET 4). I use SQL Server for my database affairs, I can run this application smoothly on my development systems (which have VS 2012 installed) but when I give EXE and my MDF files to someone who don't have VS2012 installed, they get an SQL server exception (also program runs but they cannot use database features), I think problem is that they don't have SQL server installed, how can I solve this problem? what should I give to my users? Is there any difference between Debug and Release versions? I deploy Debug EXE which runs but as mentioned SQL server features are not usable

SQL Server Compact error: Unable to load DLL 'sqlceme35.dll'. The specified module could not be found

I'm developing a Windows Forms application using Visual Studio 2008 C# that uses an SQL Server Compact 3.5 database on the client. The client will most likely be 32 bit Windows XP or Windows Vista machines. I'm using a standard Windows Installer project that creates an MSI file and setup.exe to install the application on a client machine. I'm new to SQL Server Compact, so I haven't had to distribute a client database like this before now. When I run the setup.exe (on new Windows XP 32 bit with SP2 and Internet Explorer 7) it installs fine, but when I run the application I get this error:
Unable to load DLL 'sqlceme35.dll'. The specified module could not be found
I spent a few hours searching for this error already, but all I could find were issues relating to installing on 64 bit Windows and none relating to normal 32 bit that I'm using.
The install application copies the all the dependent files that it found into the specified install directory, including the System.Data.SqlServerCe.dll file (assembly version 3.5.1.0). The database file is in a directory called 'data' off the application directory, and the connection string for it is
<add name="Tickets.ieOutlet.Properties.Settings.TicketsLocalConnectionString" connectionString="Data Source=|DataDirectory|\data\TicketsLocal.sdf" providerName="Microsoft.SqlServerCe.Client.3.5" />
Some questions I have:
Should the application be able to find the DLL file if it's in the same directory, that is, local to the application, or do I need to install it in the GAC? (If so, can I use the Windows Installer to install a DLL file in the GAC?)
Is there anything else I need to distribute with the application in order to use a SQL Server Compact database?
There are other DLL files also, such as MS interop for exporting data to Excel on the client. Do these need to be installed in the GAC or will locating them in the application directory suffice?
You don't need it to be in the GAC for SQL Server Compact to run, and it will pick them up from the application directory. There are several ways to deploy an SQL Server Compact project. The two main ways are:
Deploying the SQL Server Compact redistributable installer with your project, but this way is painful and also can be unistalled by the end user, or upgraded by Windows updates and breaking your application.
Including the DLL files in your application folder. Depending on the features of SQL Server Compact you are using (replication or whatever), there is a handful of DLL files to deploy in your application folder.
If you have SQL Server Compact installed on your machine, they are most likely located at "C:\Program Files\Microsoft SQL Server Compact Edition\v3.5". They can be added to the project in Visual Studio and then set their project output type to "copy always". And the main reference to System.Data.SqlServerCe that you have in your project references should have copy local set to true.
sqlceca35.dll
sqlcecompact35.dll
sqlceer35en.dll
sqlceoledb35.dll
sqlceqp35.dll
sqlcese35.dll
If you have these all set, then in your installer project all you have to include is the project output of this project and you're good. In my opinion this is the only way to go. It is a simple deployment, of a couple of files and you are in control of what DLL versions your application uses.
I hope that helps.
I had a similar problem, a Visual Studio 2008 Windows application targeting 32-bit Windows XP and Windows Vista that used SQL Server Compact 3.5 SP1 - that then got this error when installed on 64-bit Windows 7:
Unable to load DLL 'sqlceme35.dll'. The specified module could not be found
I was embedding an MSI for SQL Server Compact into the installer for the application.
Following this rather confused discussion on MSDN revealed that I needed to use the 64-bit MSI for SQL Server Compact on 64-bit machines. D'oh! That is, from page Microsoft SQL Server Compact 3.5 Service Pack 1 and Synchronization Services for ADO.NET version 1.0 Service Pack 1 for Windows Desktop I needed SSCERuntime-ENU-x64.msi rather than SSCERuntime-ENU-x86.msi for 64-bit machines.
How to: Deploy a SQL Server Compact Edition Database with an Application should help, at least with your first two questions.
In general, I think you should not install anything in the GAC for a single application.
The following provide a solution to the problem and an explanation also.
Troubleshooting: Can’t load SQL Server Compact DLL
SqlCeException on application's first use of SQL Server Compact
Laxmi Narsimha Rao Oruganti 's blog
I hope this helps.

Resources