In most cases, most of non-IT employees have no privileges to connect databases in the company. But there is no one who can deny that data is becoming more and more important in our works even lives. So as long as we have the opportunities to use database, please seize it. You will find a new world of it.
In my experience, I use UIPath to connect with the databases like mysql, which is easy installed in our personal computers, and oracle which is more complicated than mysql.
On the whole, to connect different databases in UIPath is very similar. In some cases, we need to do other things to make it work.
Now, I will show you how to connect mysql database in UIPath:
1, download database package from Manage Package in UIPath.
2, install ODBC connector for the database, then add ODBC data source in Windows tools.(notice the connector is 32-bit or 64-bit which decides the ODBC bit)
3, backing to UIPath, add Connect to database activity, then choose the ODBC source added.
4, after connecting database successfully, we can run sql query to retrive datatable. What's more, we also can pass parameters to sql query using "?" . If pass many parameters to sql, just adds them in order. As below:
There are 2 extra points I want to add.
1, In the newest version of UIPath, when using Insert activity to add records into database you will get an error. If you use the old version UIPath like 21.10.5 run the same activity, which will work perfectlly.
2, If you want to connect Oracle database, configure tnsnames.ora file first. Then copy the file into project folder. Finally, it works.