Articles → AUTOMATION ANYWHERE → Excel As A Database In A2019
Excel As A Database In A2019
Prerequisite
Sample Excel
Click to Enlarge
Example
- Connect to the excel.
- Export data to datatable.
- Loop through all rows of the data table.
Connect To Excel
- Drag and drop the "Connect" action of the "Database" activity.
Click to Enlarge
- In the property window, set the "Connection Mode" as "Default" and "Connection String" as
Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Users\karan\OneDrive\Desktop\a.xlsx;Extended Properties="Excel 12.0 Xml;HDR=YES;IMEX=1"
Click to Enlarge
Export Data To Datatable
- Drag and drop the "Export to data table" action from the "Database" command.
Click to Enlarge
- In the property window, enter the select statement and assign the result of the select statement to a variable.
Click to Enlarge
Loop Through All The Rows Of The Datatable.
Click to Enlarge
Output