In this post, I would like to share how to resolve an error installing SQL Server Data Tools (SSDT) 2017 - Setup Failed: Incorrect function (0x80070001), which happens to me frequently whenever I try to install SQL Server Data Tools 2017 version on some computers.
What is SQL Server Data Tools (SSDT)?
According to the official Microsoft documentation, SQL Server Data Tools (SSDT) transforms database development by introducing a ubiquitous declarative model that spans all phases of database development in Visual Studio.
You can use SSDT's Transact-SQL design capabilities to compile, debug, maintain, and refactor databases. It can work with a database project or directly with a connected or external database instance.
In summary, SSDT is a free IDE for BI and database analysts to work with database projects (SQL Database Projects / SQLCLR), Integration Service projects (SSIS), Analysis Services (SSAS) and Reporting Services (SSRS) , so it is essential for anyone working in the data field with Microsoft data tools.
If we analyze the SSDT download page, we can see that versions 2019 and 2022 (preview) already exist for download, as components of Visual Studio, while versions 2017 and earlier were standalone installers that already installed a simplified copy of Visual Studio, known as Visual Studio Shell ( SSDT 2014 to 2017) or BIDS (SSDT 2005 to 2012).
The biggest problem I see with newer versions and ends up generating many doubts throughout the technical community, is that you need to install Visual Studio Community Edition to use SSDT, if you don't have a Visual Studio license.
If we analyze the Official Visual Studio Community Documentation, note that using the Community edition has some limitations for commercial use:
Translation: For all other usage scenarios: In non-enterprise organizations, up to five users can use Visual Studio Community. In business organizations (ie, those with over 250 PCs or over $1 million in annual revenue), no use is allowed beyond the open source, academic research, and classroom learning environment scenarios described above .
That is, if you work for a large company, you cannot use Visual Studio Community. And what about SSDT? How would you be in this situation? Well, so far, I haven't found any official documentation mentioning this exception, so many people are afraid to use the newer versions of SSDT because of this licensing question and end up opting for the 2017 version, the latest version with standalone installer.
Error installing SQL Server Data Tools (SSDT) 2017
Going back to the original problem of this article, sometimes I can install SSDT 2017 normally and sometimes I can't because the error Incorrect function (0x80070001) happens during the installation.
Analyzing the installation error log, I couldn't identify a possible cause or solution for this.
To resolve this, we will do offline installation of SSDT 2017 as the issue occurs when trying to download some features from the installer. Download standalone installer this link here ou click on this other link here to go straight to the download link.
Download the vs_sql.exe file, clicking on this link here and save in the same directory where you downloaded the SSDT installer (SSDT-Setup-ENU.exe).
Open the DOS prompt as an administrator:
Now navigate to the folder where you downloaded the files and type the command:
vs_sql.exe --layout C:\diretorio_onde_quer_salvar\ --lang en-us
After that, the installation will start and the files will be downloaded to the chosen directory:
During the download process, I noticed it was over 1h at 69.62%. I pressed the “Enter” key, the installer showed this error message and continued the process.
Installation completed with errors:
To fix this problem that occurred to me, type the command below: (only do this if you also had download errors)
vs_SQL.exe --layout C:\SSDT2017 --fix
Navigate to the directory where you downloaded the layout files (in my case, C:\SSDT2017) using the “cd” command and type the command below in the Command Prompt window to install Visual Studio Shell and Database Project:
There's not much to change here, just click on the Install button (or maybe change the installation path):
Visual Studio Data Tools 2017 Installed
Now you can install SQL Server Data Tools 2017 (SSDT) through the normal installer (SSDT-Setup-ENU.exe), remembering to check the SSIS, SSRS and SSAS options:
At the end of the process, we see that the installation was completed successfully!
After restarting the server, I open Visual Studio 2017:
And the SQL Server project templates (Database Project / SQLCLR), Analysis Services (SSAS), Integration Services (SSIS) and Reporting Services (SSRS) are working normally.
And that's it, folks!
A big hug and until next time.
Thank you so much. I have been floundering in the mud and you really helped me out here. I really appreciate the post. This was fantastic! If you were here, I would buy you at least a cappuccino!
Thanks for the help, but I need to ask about how you got the layout files, in your case the c:\ssdt2017. How can I get mine? I have searched for it.
Very very good, it solved my problem.! Congratulations.
Thanks so much for the solution. Finally setup completed.
hello buenas yo download them from the assets and put them in the miso place, but when you refer to C:\SSDT2017 this file is one of those that usted said that they will download are from the files that usted put for downloads C:\SSDT2017 is one of they are the other
Thanks for the help. I have installed the SSDT as per the instructions. One question, Can we delete the files created during –layout process? Because it is consuming 3 GB space.
Yes, you can delete these files.
Hello Dirceu, the step where you referenced the downloaded layout file, where did you get it? Your c:\ssdt2017, how can I find mine?