SSIS - Reference DLL Dynamic Directory - ssis

I'm trying to create some Crystal Reports via SSIS which works wonderfully when it can find the DLLs, but not so much when it can't.
I've gone into the package to add the references, but the problem is when the package is running from SQL Agent it can't find the references since they aren't in that drive path.
Is it possible to put the DLL files in separate locations that can be accessed independently and have the path to the DLLs be stored in a variable and then referenced either programmatically or have the path defined dynamically?
Thanks

All DLL references used in SSIS need to be registered with the GAC.
You have a couple of different options to do that, check out my previous answer for the how: How do I use COM reference within SSIS package?

You could try copying the DLLs to the SQL Server binary folder (in my case "C:\Program Files (x86)\Microsoft SQL Server\100\DTS\binn").
I had this problem calling a .Net library that uses HtmlUnit. The NuGet version I'm using doesn't have a Strong Name, and so can't be GACed, but that worked for me.

Related

How to reference JSON.NET in SSIS

I need to parse some JSON in an SSIS package. JSON.NET seems popular and well supported. I downloaded the latest version, but...
My development machine already has 97 different copies of Newtonsoft.Json.dll in various places. The target deployment server has over 120. Installing yet another one isn't going to help matters.
I'm using VS 15.9 for development. I read that JSON.NET is already built-in to VS here, but I sure can't find it anywhere in "Add reference". using in C# doesn't seem to bring up anything.
How do I get started?
How will the reference translate when I deploy? Do the .DLL paths need to be the same on dev machine/server, or can it work off some kind of signature?
EDIT:
I've got started, and it works beautifully. I referenced this file:
C:\Program Files (x86)\Microsoft SQL Server\140\DTS\Extensions\Common\Newtonsoft.Json.dll.
It exists on both my target servers. But is this best practice? I have no idea on how best to reference DLLs from SSIS.

How can I add a reference to Microsoft.SqlServer.DTSRuntimeWrap from an SSIS Script Task?

How can I add a reference to Microsoft.SqlServer.DTSRuntimeWrap from an SSIS Script Task? I can add a references to the .dll from regular Visual Studio projects or from Script Coponents. For some reason I am not able reference the .dll from Script Tasks. I tried copying the path from the Visual Studio project but I get an error saying "The file path is not valid". The path on my computer is "C:\Windows\assembly\GAC_32\Microsoft.SQLServer.DTSRuntimeWrap\10.0.0.0__89845dcd8080cc91\Microsoft.SQLServer.DTSRuntimeWrap.dll". FYI, I am working on a Windows Server 2008 R2 64-bit machine. How can I add a reference to Microsoft.SqlServer.DTSRuntimeWrap from an SSIS Script Task? Thanks
You cannot add references to your script task in SSIS. I know that's not what you wanted to hear but the script task does not have the full functionality of a vs project.

Connect to MYSQL with VB.NET

I am trying to connect to a MYSQL database using VB.NET to handle some simple tasks at a page level. Usually the connections are made to a MYSQL database. I have downloaded a MYSQL-CONNECTOR 6.0.7. How do I reference or add this to my web project so that I can create the connection and use the provided methods?
In the unzipped package I download I do not see any dll files so not sure what to do with this ATM, I am used to seeing a bin folder which contains this. Maybe I have a bad download any suggestions?
If you downloaded the ZIP archive, then generally this is the source code distribution. You need to open MySQLClient.sln in Visual Studio and build the MySql.Data project to produce MySql.Data.dll in the bin folder.
the last version is 6.4.3 download from http://www.mysql.com/downloads/connector/net/ , add reference for the unzip folder and us it as sqlClient it has the same class only have to append My to the class name

SSRS - Custom assembly in location other than server bin directory

Is it possible to deploy a custom assembly to a location other than the Reporting Service's bin directory?
I know that deploying to the GAC would likely work, but I'm more curious about using an arbitrary directory on the server dedicated to deploying custom assemblies.
I'm not opposed to altering any rs config files, if a possible solution involves that.
According to MSDN, you must deploy to the \bin directory or install in the GAC (MSDN link.) Those are your only options.
The Microsoft SQL Server forum has an identical discussion going on. A Microsoft support engineer gave the same answer: it can't be done.

How to add reference to an external DLL from within script task?

How can I add reference to an external assembly from within a script task and deploy the package to a server along with the newly added external assembly?
If this is in reference to your other recent question, then the only proper way to get the correct version of a Word DLL on the server where you want to deploy to is to install the proper product onto the server. Most DLL's (especially from products like Microsoft Office) are not redistributable (meaning you are not legally allowed to copy them from machine to machine without the underlying product installed). If a DLL from Microsoft is redistributable, then there will be a document accompanying the DLL that tells which DLL's are allowed to be copied from machine to machine and what the correct process for doing so is.
If this is not in reference to that question, then can you provide more detail about what it is you are trying to do so that we can help you more.
Assuming you are using SSIS 2008 (it was a bit different for SSIS 2005) -
the referenced assembly needs to be installed into GAC (Global Assembly Cache)
on target machine where you run the package.