Search code examples
c#sql-servervisual-studio-2015ssissql-server-data-tools

SSIS 2017 Upgrade issue


We are upadating the packages(packages are in package deployment model) from SSIS 2012 to SSIS 2017. There are lots of script components in all the packages. When we are upgrading the packages we are having an error

Description: CS0234 - The type or namespace name 'Dts' does not exist in the namespace 'Microsoft.SqlServer' (are you missing an assembly reference?), ScriptMain.cs, 14, 26 End Error

Configurations: SQLserver 2017 Visual studio enterprise 2015 + SSDT 2015

We have tried different options of deleting and re-adding the assemble file in the script component. Looks like the Microsoft.Sqlserver.ManagedDts assemble file is having issues for 2017 version. When we upgrade the packages to SSIS 2016 the packages work fine.

When we try to run the SSIS 2016 packages from Sqlserver agent job in SQLSERVER 2017 it is trying to upgrade the packages to 2017 and throw up the similar error as above.

Any solutions would be appreciated.


Solution

  • We have a mix of straight SSIS and BIML generated packages all suffering the same issues. Again, struggling for answers

    We did find a workaround, but it's far from ideal :

    1. View code on the dtsx package
    2. Find the Project node
    3. Find the PropertyGroup node which contains the AssemblyName node
    4. Add a TargetFrameworkVersion to this PropertyGroup, with a value of v4.5
    5. Save

    Now if you open the package you can build/Execute your package