System.Data.SqlClient / sni.dll in coded automation -> Unable to load DLL 'sni.dll'

I get “Unable to load DLL ‘sni.dll’” when I use Microsoft.Data.SqlClient in coded automation. For the last year or so I’ve been using oledb to side step this specific issue in UiPath. How ever, it is so much more convinient to use SqlConnection instead of OleDb. I know that there are some potential work around like copying the dll etc. But this is not a very good approach in a quite critical production environment.

As for now I’m looking for a safe workaround. Help. =)

Hi @rickard.nordstrom

This might not be the solution just yet, but more context can be found in this topic:

But more specifically. Our own UiPath Database package uses this as a workaround:

(it is one of the ones that we showcase on the open repo for reference)