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.
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).
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
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:
At the end of the process, we see that the installation was completed successfully!
And that's it, folks!
A big hug and until next time.