Access Database engine OLEDB in windows server 2016 - sql-server

I have an application that uses Microsoft ACE OLEDB 12.0 driver and hence I have installed 2007 Office System Driver: Data Connectivity Components in my system.
I also have created SSIS packages to pull data from the excel and csv files which get's inserted into the SQL tables using the Microsoft ACE OLEDB 12.0. Below is my connection string
Provider=Microsoft.ACE.OLEDB.12.0;Data Source=c:\myFolder\myOldExcelFile.xls;
Extended Properties="Excel 8.0;HDR=YES";
I wanted to move these applications to the server environment for deployment and When I reached out to the IT for getting Office 2007 system driver to be installed, they said it's not supported in Windows server 2016 and have security vulnerabilities.
Hence I wanted to know whether we have any alternate Microsoft OLEDB provider for SSIS operation? I tried installing office 2010 however I got the error message that
Microsoft OLEDB 12.0 is not registered on my machine.
Will installing Microsoft Access Database Engine 2016 Redistributable help me out in resolving the problem. If yes what will be my connection string. Is the below one correct?
Provider=Microsoft.ACE.OLEDB.16.0;Data Source=c:\myFolder\myOldExcelFile.xls;Extended Properties="Excel 12.0;HDR=YES";
The office 2016 oledb is also not supported in windows server 2016. Hence what security vulnerabilities will occur when we install Office 2007 or 2016 on windows server 2016?
Any help will be highly appreeciated.

Microsoft OLEDB 12.0 is not registered on my machine.
Since you installed Access Database Engine 2010 and you received the error above, then it looks like it is a 32/64 bit problem.
Make sure you installed both redistributables 32 and 64.
If you need to install AccessDataBaseEngine x64 alongside with 32-bit installation, you need to run the installation in passive mode:
Passive mode installation steps
Open the Command Prompt by typing cmd in the Windows search box under the Start menu and selecting cmd.exe
Type the file path and file name of the 64-bit Access Database Engine 2010 install file, followed by a space and /passive (this runs the installation without showing any error messages).
Open the Registry Editor by typing regedit in the Windows search box under the Start menu and selecting regedit.exe
Delete or rename the mso.dll registry value in the following registry key:
"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\14.0\Common\FilesPaths"
More details and screenshots are found in the link below
Reference
How to install 64-bit Microsoft Database Drivers alongside 32-bit Microsoft Office

Related

Excel file import into SQL [duplicate]

I get this error when I try to connect to any excel through MSSQL Server Data Import i.e. SSIS package The Microsoft.ACE.OLEDB.16.0 provider is not registered on the local machine. (System.Data)
It is not the same version I think some other patching is needed
For anyone that is still stuck on this issue after trying the above. If you are right-clicking on the database and going to tasks->import, then here is the issue. Go to your start menu and under sql server, find the x64 bit import export wizard and try that. Worked like a charm for me, but it took me FAR too long to find it Microsoft!
Note: I am running SQL 2016 Developer 64bit, Office 2016 64bit.
I had the same issue and solved it by downloading the following:
Download and install this:
https://www.microsoft.com/en-us/download/details.aspx?id=54920
Whatever file you are trying to access/import, make sure you select it as a Office 2010 file (even though it might be a Office 2016 file).
It works.
Source
As a quick workaround I just saved the workbook as an Excel 97-2003 .xls file. I was able to import with that format with no error.
If you have OS(64bit) and SSMS(64bit) and already install the AccessDatabaseEngine(64bit) and you still received an error, try this following solutions:
1: direct opening the sql server import and export wizard.
if you able to connect using direct sql server import and export wizard, then importing from SSMS is the issue, it's like activating 32bit if you import data from SSMS.
Instead of installing AccessDatabaseEngine(64bit) , try to use the AccessDatabaseEngine(32bit) , upon installation, windows will stop you for continuing the installation if you already have another app installed , if so , then use the following steps. This is from the MICROSOFT. The Quiet Installation.
If Office 365 is already installed, side by side detection will prevent the installation from proceeding. Instead perform a /quiet install of these components from command line. To do so, download the desired AccessDatabaseEngine.exe or AccessDatabaeEngine_x64.exe to your PC, open an administrative command prompt, and provide the installation path and switch Ex: C:\Files\AccessDatabaseEngine.exe /quiet
or check in the Addition Information content from the link below,
https://www.microsoft.com/en-us/download/details.aspx?id=54920
An alternative that works for me is to simply convert to a CSV.
Against other answers here, you can just install "ACEDB driver 64-bit" next to the other 64-bit Microsoft program.
In my case, I had "Microsoft 365" 64-bit (Microsoft Office 365) installed.
Because of the error
'Microsoft.ACE.OLEDB.16.0' provider is not registered on the local
machine. (System.Data)
I tried installing Microsoft Access Database Engine 2016 Redistributable. But I got errors for 32-bit and 64-bit installers.
64-bit:
You cannot install the 64-bit version of Microsoft Access Database
Engine 2016 because you currently have 64-bit Office products
installed. If you want to install 32-bit Microsoft Access Database
Engine 2016, you will first need to remove the 64-bit installation of
Office products. After uninstalling the following product(s), rerun
setup in order to install 32-bit version of Microsoft Access Database
Engine 2016: Office 16 Click-to-Run Extensibility Component 64-bit
Registration
or 32-bit:
You cannot install the 32-bit version of Microsoft Access Database
Engine 2016 because you currently have 64-bit Office products
installed. If you want to install 32-bit Microsoft Access Database
Engine 2016, you will first need to remove the 64-bit installation of
Office products. After uninstalling the following product(s), rerun
setup in order to install 32-bit version of Microsoft Access Database
Engine 2016: Office 16 Click-to-Run Extensibility Component 64-bit
Registration
I could not uninstall single components:
The steps:
No need to uninstall and reinstall anything.
Press "Download" at Microsoft Access Database Engine 2016 Redistributable
Choose AccessDatabaseEngine_X64.exe. No need to install 32-bit AccessDatabaseEngine.exe, against other answers.
Run the executable from command prompt:
C:\Users\myuser\Downloads>AccessDatabaseEngine_X64.exe /quiet
Press OK for the administrator rights if asked for.
After this, my macro could fetch data from an Excel worksheet. I checked my local Microsoft Access of the Microsoft 365 package and it still worked.
Credits go to You cannot install the 32/64 bit version of Microsoft Access Database Engine because you currently have 64/32 bit Office and its source at How to install Microsoft.Ace.oledb 32 bit with Office 64-bit?.
ACE.oledb.16.0 dosen't work in the 64-bit os
download patch from
https://www.microsoft.com/en-us/download/details.aspx?id=13255
If you have Office 365:
Download 32 Bit version here
Run Command Prompt as Administrator --> C:\Downloads\AccessDatabaseEngine.exe /quiet
Close SSMS & Reopen, Try Importing File again.
Doesnt work?
Download 64 bit version here
Run Command Prompt as Administrator --> C:\Downloads\AccessDatabaseEngine_X64.exe /quiet
Close SSMS & Reopen, Import File.
Note:
Path to dowbloaded executable might be "C:\Downloads\User\USERNAME\Downloads\AccessDatabaseEngine.exe" for example
You have to use now the new XLSX-Driver from Access-Redist (32/64-Bit).
The current XLS-Driver are corrupted since last cumulative update.
Follow these steps:
Go [here][1], download Microsoft Access Database Engine 2016 Redistributable and install
Close SQL Server Management Studio
Go to Start Menu -> Microsoft SQL Server 2017 -> SQL Server 2017 Import and Export Data (64-bit)
Open the application and try to import data using the "Excel 2016" option, it should work fine.
After having both installed the Microsoft Access Database Engine 2016 Redistributable and found the x64 bit import export wizard as instructed in the answers above, I had one last hoop to jump through. I got this error 'Executing the query "CREATE TABLE ...." failed with the following error: "Culture is not supported ... 3072 (0x0c00) is an invalid culture identifier."'
The fix was to go to Control Panel -> Clock and Region -> change my "English (Finland)" region to pure Finnish (Finland). Other more traditional cultures such as en-US will work too. I think I first saw this solution here: Fix culture is not supported: 3072 by changing Region Formats

SSIS Error "To run a SSIS package outside of SQL Server Data Tools you must install Standard Edition (64-bit) of Integration Services "

I am using Visual studio ultimate 2012, SQL Server 2017 and Sql Server Data tools 2012. I am working with windows 10 64 bit.
My package consists of script tasks(c#) and Sql commands and it runs successfully from SSDT, but while trying to run my package from CMD i am getting
To run a SSIS package outside of SQL Server Data Tools you must install Standard Edition (64-bit) of Integration Services.
If i make another empty package and try to run it then it runs successfully too.
Please help.
(1) Integration Services (Shared feature) installation
I think that the issue is that you have installed SQL Server Data Tools (SSDT) for Visual Studio but you didn't install the Integration Services (Shared feature) from the SQL Server Installation which is necessary to execute .dtsx packages outside of visual studio.
For more information check the following link:
SSIS Error – “To run a SSIS package outside of SQL Server Data Tools you must install…”
(2) Execute using dtexec(32-bit)
Another thing you can try is to execute package via 32-bit dtexec.
As mentioned in the following Microsoft Documentation:
On a 64-bit computer, Integration Services installs a 64-bit version of the dtexec utility (dtexec.exe). If you have to run certain packages in 32-bit mode, you will have to install the 32-bit version of the dtexec utility. To install the 32-bit version of the dtexec utility, you must select either Client Tools or Business Intelligence Development Studio during setup.
By default, a 64-bit computer that has both the 64-bit and 32-bit versions of an Integration Services command prompt utility installed will run the 32-bit version at the command prompt. The 32-bit version runs because the directory path for the 32-bit version appears in the PATH environment variable before the directory path for the 64-bit version. (Typically, the 32-bit directory path is :\Program Files(x86)\Microsoft SQL Server\100\DTS\Binn, while the 64-bit directory path is :\Program Files\Microsoft SQL Server\100\DTS\Binn.)
More info at:
How to execute a package in 32-bit mode using dtexec.exe?
Also, similar issues was mentioned in other links, you can check them for more information:
SQL Server Central Forum - Run a SSIS package outside of SQL Server Data Tools you must install of Integration
Code Project - How To run a SSIS package outside of SQL Server Data Tools ?
MSDN - To run a SSIS package outside of SQL Server Data Tools you must install Standard Edition of Integration Services or higher
To run a SSIS package outside of SQL Server Data Tools you must install Move File to Archive of Integration Services or higher
SE DBA - Error: “To run a ssis package outside of sql server data tools you must install [send successful email] of Integration Services or higher.”
Adding to Hadi's answer, the change would be to use the right version which in my case was to use
C:\Program Files\Microsoft SQL Server\130\DTS\Binn>
Instead of
C:\Program Files (x86)\Microsoft SQL Server\130\DTS\Binn>
I had the same error and my integration services of 2017 was installed, so the suggested solution was not relevant.
i tried many options including uninstall and re-install, what solved finally was an upgrade to ENTERPRISE EDITION!
I found out that in a server where the dtexec ran successfully an ENTERPRISE VERSION was installed, while in the problematic server there was not an ENTERPRISE edition.
How did i find it? i ran the following in both servers:
run setup.exe file of SQL SERVER 2017 installation
on the left menu you will see "tools" - press the link
find: "installed SQL server features discovery report"
you will see in edition column an empty cell vs. "Enterprise Edition"
which is the successful one!
how did i upgrade in the problematic server?
run setup.exe file of SQL SERVER 2017 installation
on the left menu you will see "maintenance" - press the link
find: "edition upgrade"
follow the instructions, in my case since my organization had an automatic updated key i just pressed "next" a few times until a successful upgrade
good luck!

what do I do to enable my Microsoft SQL Server 2008 install and run on my windows7 computer

I tried Installing Microsoft SQL Server 2008 at first, Its installation was going smoothly until I closed my computer to attend to an occasion. Before I tried installing it for a second time, I compressed my C drive(C:) so as to create more storage space. On Installing it again, It couldn't install as a dialog box displayed showing that my attributes doesn't match.
I uncompressed my C: drive and tried installing it again yet it couldn't install. Finally I tried for the last time just to see the image below.
What do I do? My computer is a 32bit OS. and window 7 Ultimate.
You should take a look at the Hardware and Software Requirements for Installing SQL Server 2008, some conditions are:
SQL Server Setup will block installations on read-only or compressed drives.
For minimum version requirements to install SQL Server 2008 on Windows Server 2012 or Windows 8, see Installing SQL Server on Windows Server 2012 or Windows 8 (http://support.microsoft.com/kb/2681562).
So please read it carefully, you can found it in the MSDN here

'Microsoft.ACE.OLEDB.16.0' provider is not registered on the local machine. (System.Data)

I get this error when I try to connect to any excel through MSSQL Server Data Import i.e. SSIS package The Microsoft.ACE.OLEDB.16.0 provider is not registered on the local machine. (System.Data)
It is not the same version I think some other patching is needed
For anyone that is still stuck on this issue after trying the above. If you are right-clicking on the database and going to tasks->import, then here is the issue. Go to your start menu and under sql server, find the x64 bit import export wizard and try that. Worked like a charm for me, but it took me FAR too long to find it Microsoft!
Note: I am running SQL 2016 Developer 64bit, Office 2016 64bit.
I had the same issue and solved it by downloading the following:
Download and install this:
https://www.microsoft.com/en-us/download/details.aspx?id=54920
Whatever file you are trying to access/import, make sure you select it as a Office 2010 file (even though it might be a Office 2016 file).
It works.
Source
As a quick workaround I just saved the workbook as an Excel 97-2003 .xls file. I was able to import with that format with no error.
If you have OS(64bit) and SSMS(64bit) and already install the AccessDatabaseEngine(64bit) and you still received an error, try this following solutions:
1: direct opening the sql server import and export wizard.
if you able to connect using direct sql server import and export wizard, then importing from SSMS is the issue, it's like activating 32bit if you import data from SSMS.
Instead of installing AccessDatabaseEngine(64bit) , try to use the AccessDatabaseEngine(32bit) , upon installation, windows will stop you for continuing the installation if you already have another app installed , if so , then use the following steps. This is from the MICROSOFT. The Quiet Installation.
If Office 365 is already installed, side by side detection will prevent the installation from proceeding. Instead perform a /quiet install of these components from command line. To do so, download the desired AccessDatabaseEngine.exe or AccessDatabaeEngine_x64.exe to your PC, open an administrative command prompt, and provide the installation path and switch Ex: C:\Files\AccessDatabaseEngine.exe /quiet
or check in the Addition Information content from the link below,
https://www.microsoft.com/en-us/download/details.aspx?id=54920
An alternative that works for me is to simply convert to a CSV.
Against other answers here, you can just install "ACEDB driver 64-bit" next to the other 64-bit Microsoft program.
In my case, I had "Microsoft 365" 64-bit (Microsoft Office 365) installed.
Because of the error
'Microsoft.ACE.OLEDB.16.0' provider is not registered on the local
machine. (System.Data)
I tried installing Microsoft Access Database Engine 2016 Redistributable. But I got errors for 32-bit and 64-bit installers.
64-bit:
You cannot install the 64-bit version of Microsoft Access Database
Engine 2016 because you currently have 64-bit Office products
installed. If you want to install 32-bit Microsoft Access Database
Engine 2016, you will first need to remove the 64-bit installation of
Office products. After uninstalling the following product(s), rerun
setup in order to install 32-bit version of Microsoft Access Database
Engine 2016: Office 16 Click-to-Run Extensibility Component 64-bit
Registration
or 32-bit:
You cannot install the 32-bit version of Microsoft Access Database
Engine 2016 because you currently have 64-bit Office products
installed. If you want to install 32-bit Microsoft Access Database
Engine 2016, you will first need to remove the 64-bit installation of
Office products. After uninstalling the following product(s), rerun
setup in order to install 32-bit version of Microsoft Access Database
Engine 2016: Office 16 Click-to-Run Extensibility Component 64-bit
Registration
I could not uninstall single components:
The steps:
No need to uninstall and reinstall anything.
Press "Download" at Microsoft Access Database Engine 2016 Redistributable
Choose AccessDatabaseEngine_X64.exe. No need to install 32-bit AccessDatabaseEngine.exe, against other answers.
Run the executable from command prompt:
C:\Users\myuser\Downloads>AccessDatabaseEngine_X64.exe /quiet
Press OK for the administrator rights if asked for.
After this, my macro could fetch data from an Excel worksheet. I checked my local Microsoft Access of the Microsoft 365 package and it still worked.
Credits go to You cannot install the 32/64 bit version of Microsoft Access Database Engine because you currently have 64/32 bit Office and its source at How to install Microsoft.Ace.oledb 32 bit with Office 64-bit?.
ACE.oledb.16.0 dosen't work in the 64-bit os
download patch from
https://www.microsoft.com/en-us/download/details.aspx?id=13255
If you have Office 365:
Download 32 Bit version here
Run Command Prompt as Administrator --> C:\Downloads\AccessDatabaseEngine.exe /quiet
Close SSMS & Reopen, Try Importing File again.
Doesnt work?
Download 64 bit version here
Run Command Prompt as Administrator --> C:\Downloads\AccessDatabaseEngine_X64.exe /quiet
Close SSMS & Reopen, Import File.
Note:
Path to dowbloaded executable might be "C:\Downloads\User\USERNAME\Downloads\AccessDatabaseEngine.exe" for example
You have to use now the new XLSX-Driver from Access-Redist (32/64-Bit).
The current XLS-Driver are corrupted since last cumulative update.
Follow these steps:
Go [here][1], download Microsoft Access Database Engine 2016 Redistributable and install
Close SQL Server Management Studio
Go to Start Menu -> Microsoft SQL Server 2017 -> SQL Server 2017 Import and Export Data (64-bit)
Open the application and try to import data using the "Excel 2016" option, it should work fine.
After having both installed the Microsoft Access Database Engine 2016 Redistributable and found the x64 bit import export wizard as instructed in the answers above, I had one last hoop to jump through. I got this error 'Executing the query "CREATE TABLE ...." failed with the following error: "Culture is not supported ... 3072 (0x0c00) is an invalid culture identifier."'
The fix was to go to Control Panel -> Clock and Region -> change my "English (Finland)" region to pure Finnish (Finland). Other more traditional cultures such as en-US will work too. I think I first saw this solution here: Fix culture is not supported: 3072 by changing Region Formats

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"

Resources