I recently went back into my Community Edition UiPath Studio to work on a project that accesses and was successfully accessing a MariaDB/MySQL database. At the Connect to database activity I was greeted with the yellow framed message “This project uses the Windows-legacy compatibility which is being phased out and will no longer be available for new projects in the next Enterprise release. Convert to windows.” When I clicked “Convert to Windows”, and all of the scrolled processing was completed, I tried to run the project. A “Runtime execution error” appeared with the following message:
Source: Connect to database
Message: Could not load file or assembly ‘Microsoft.Data.Sq|Client, Version=188.8.131.52,
Culture= neutral, PublicKeyToken=23ec7fc2d6eaa4a5’ or one of its dependencies. The system
cannot find the file specified.
Exception Type: System.IO.FileNotFoundException
What does this mean and how do I get my Database connection to work again?
Yes, I am using version 1.7.1 of the Database package.
My connection string (which worked before) is “Dsn=MariaDB;uid=root” and the Provider name is “System.Data.Odbc”. These still work in another UiPath project in which I use Connect to database.
But, in the project in which I get the error, even if I add a new Connect to Database activity and configure it from scratch, I still get the message Connect to database: Could not load file or assembly ‘Microsoft.Data.SqlClient, Version=184.108.40.206, Culture=neutral, PublicKeyToken=23ec7fc2d6eaa4a5’ or one of its dependencies. The system cannot find the file specified.
The error states syntax error, do you have a way to test your query outside ui path to see if it runs without problems? In case it does. You could try either A) use a different connector (Provider Name argument) or B) downgrade even further until you match the version that was working for you. I know that is not ideal but maybe a work around until Ui Path fix the problem