Help Centre › Building Processes
This article describes the RPA Excel functionality to query data using AI.
For a full list of available functions, please read EXCEL functions.
Description
Ask a natural language question about the data in a sheet and get an AI-generated answer. Reads up to 50 rows of sheet data and the workbook context (columns, dimensions, sample data), sends it to AI along with your question, and stores the answer in a variable. Returns numeric values for counts/sums or text for explanations.
Setting it up
To use the EXCEL Query data using AI function, follow these instructions:
{{popups:rpas/add:action=excel-query}}
Once on a process map:
- Navigate to the process where you would like to add the EXCEL Query data using AI function
- Click on the green button's drop-down (right side of the green button labelled "Process")
- On the menu that appears, click on the "+ Activity" item
- From here you can select the EXCEL Query data using AI option
- Click "Add" once you are done
Input parameters
| Parameter | Required | Type | Default | Description |
|---|---|---|---|---|
| File path | Yes | Text | – | Full path to the Excel file. |
| Sheet | Yes | Text | – | The sheet containing the data to query. |
| Question | Yes | Textarea | – | Your question in plain English. |
| Variable | Yes | Text | query | Name of the variable where the AI answer will be stored. |
Output variables
The answer is stored in the specified variable. Numeric answers (counts, sums) are stored as numbers; text answers as strings.
Errors
| Error | Description |
|---|---|
| File not open | The Excel file must be open before using this function. |
| Sheet not found | The specified sheet does not exist. |
| AI not configured | The AI API endpoint is not configured. |
Example questions
- How many unique suppliers are there?
- What is the total of the Amount column?
- Which customer has the highest invoice value?
- Are there any duplicate invoice numbers?
- What is the average order value for January?
Tips
- Be specific with column names for best results.
- For large datasets, the AI sees the first 50 rows – phrase questions accordingly.
- Use the result in subsequent steps:
{query}or{variable_name}.