Fix For Using Azure Active Directory to Connect to SQL
Hello! The other day someone was kind enough to get in touch with me to thank me for some post I wrote back last year. For the sake of brevity, there's all sorts of nastiness in trying to authenticate using Azure Active Directory when connecting to an Azure SQL Instance/Managed Instance. And the function what I wrote aimed to automate uninstalling and installing the “correct” version of the adalsql.dll required. Thing was I admitted it was a hack in the original post, and the worst thing about a hack is that they tend to be a bit….