In Power Automate, filter Excel table rows by entering an OData-style condition in the Filter Query field of the Excel Online (Business) action List rows present in a table. For example, use Status eq 'Open' to return rows whose Status value is Open; the query filters what the flow retrieves and does not change the worksheet.
What the Excel Filter Query does
A Filter Query narrows the rows returned by the Excel connector before the flow continues to later actions. It is useful when a workbook table contains many records but a flow needs only a subset, such as open requests, orders above a threshold, or records for one region. A narrower response can also reduce the amount of data subsequent steps have to process.
The field uses a form of OData query syntax. It is not an Excel formula, a worksheet filter, or the expression language used by every other Power Automate action. In particular, do not enter an Excel function such as =FILTER(A2:D100,D2:D100="Open") in this field. The connector expects a condition about table columns and row values.
Filtering here is non-destructive: it selects which rows the action returns but does not delete, hide, or edit rows in the workbook. If the flow should change the workbook, add a separate action, such as an update or delete row action, and take care to identify the intended row correctly.
Where to enter the query
- In Power Automate, create or edit a flow and add the Excel Online (Business) action List rows present in a table.
- Select the workbook location, document library or folder, file, and table. The data must be in an Excel table, not just a range of cells.
- Expand the action’s advanced parameters if necessary, then enter the condition in Filter Query.
- Save and run the flow, then inspect the action’s output to confirm which rows were returned.
Use the table’s column headers as the property names in the query. For example, a table with headers OrderID, Status, and Total can be filtered with Status eq 'Open'. Clear, stable headers without unusual punctuation make queries easier to maintain. If a header contains spaces or special characters and the query fails, try simplifying the header in Excel, then refresh or reselect the table in the action.
Basic syntax and practical examples
A condition generally has a column name, an operator, and a value. Text values are enclosed in single quotes; numeric values are ordinarily written without quotes. The query is plain text in the action field, not wrapped in an Excel formula or a Power Automate expression unless you are deliberately building it dynamically.
- Exact text match:
Status eq 'Open'returns rows with Status equal to Open. - Not equal:
Region ne 'East'selects rows whose Region is not East. - Numeric comparison:
Quantity gt 10asks for quantities greater than 10. The familiar comparison operators includegt(greater than),ge(greater than or equal),lt(less than), andle(less than or equal); confirm support with a small test because Excel connector filtering is not the full set of capabilities of every OData service. - Text search: OData-style functions such as
contains(Region,'West')orstartswith(Customer,'A')may be available for a connector query, but support can depend on the action and service. Test these against your table before relying on them in a production flow.
For example, suppose a table has a numeric Quantity column and a text Status column. A simple query such as Status eq 'Open' is a good first test. If you need both open rows and rows with a quantity over ten, try a combined condition such as Status eq 'Open' and Quantity gt 10 only after confirming that the connector accepts the comparison and conjunction for your workbook. If it reports an invalid filter, split the logic into supported conditions or retrieve rows and filter them in a later flow action.
Text, numbers, dates, and dynamic values
Match the query’s value type to the column’s actual contents. A text value such as 00125 is not necessarily the same thing as the number 125: if identifiers have leading zeroes, store and treat them as text. For a numeric column, a comparison such as Total gt 100 is normally written without quotes. If numbers are stored as text, numeric comparisons may not behave as expected.
Date filtering deserves extra care. Excel stores dates as serial numbers internally, while the connector may expose values in a formatted or serialized form. The exact filter representation can depend on how the table and connector return the column. Do not assume that a displayed value such as 11/02/2026 is automatically valid as a query literal. Inspect a returned row, consult the connector’s supported filter format, and test with dates on either side of the intended boundary. For recurring date windows, another approach is to retrieve a manageable set of rows and compare normalized values in Power Automate.
A fixed query is easiest to read, but flows often need a value supplied by a trigger, such as a customer ID or requested status. Dynamic content can be inserted in the query field, though the final text must still be valid query syntax. Text values need single-quote delimiters; numbers generally do not. If a supplied text value itself contains an apostrophe, such as O’Brien, the apostrophe must be escaped according to OData string-literal rules, typically by doubling it. Test unusual input, and avoid assembling query text from untrusted input without validating it.
Combining conditions and choosing the right approach
OData syntax commonly uses and and or to combine conditions, but the Excel connector may support a narrower subset than a general OData endpoint. For example, the intended logic might be status is Open and region is West. A candidate query is Status eq 'Open' and Region eq 'West'. Verify that it runs successfully and returns the expected records. Parentheses and more complex nested logic are especially worth testing rather than assuming they will be interpreted as in a full OData implementation.
Use the query field when the required condition is supported and you want to reduce rows at the source. Use Filter array when the needed logic is unsupported or easier to express after the rows have been retrieved. Filter array works on an array already available in the flow, so it can mean that more data is read from Excel first. For a large workbook, compare that cost with the practical limits of the Excel action and consider whether the data belongs in a system designed for more extensive querying.
These approaches are not the same as applying a visible filter in Excel. A worksheet filter changes what a person sees in the workbook; a connector query controls the action’s returned data. Similarly, the Power Automate expression language’s filter() concepts and the Excel worksheet function FILTER are not interchangeable with the OData text expected in this field.
Row limits, pagination, and workbook requirements
The action reads rows from an Excel table. If the data is only a plain cell range, format it as a table in Excel and give the table and its headers sensible names. In Microsoft 365 Excel for Windows, select the data and choose Insert > Table, then confirm whether the table has headers. Excel for the web has a similar Insert > Table route; labels and ribbon layout can vary slightly. The flow’s table selector must point to the correct table in the correct file.
By default, List rows present in a table may return only a limited number of rows; the commonly encountered default is 256. To request more, open the action’s Settings and enable Pagination, then set a threshold appropriate to the flow. Pagination does not remove all service or workbook limits, and a large result can take longer to process. A restrictive Filter Query can help, but check the actual run output rather than assuming that every matching row was returned.
Excel workbooks used by flows also need to be accessible to the connection account. A file that is moved, renamed, unavailable, or being edited in a conflicting way can cause failures unrelated to query syntax. Keep the file in a supported business location, make sure the selected table exists, and avoid having simultaneous processes update the same workbook when that could cause a lock or conflicting changes.
Common errors and how to troubleshoot them
- Invalid filter clause: Check spelling, spaces, single quotes around text, and the operator. Remove added clauses and test one simple equality condition first.
- No rows returned: Confirm that the values match the table data exactly, including capitalization, spaces, and hidden characters. Check that the flow points to the intended file and table.
- Some rows are missing: Review pagination settings and the action’s run output. Also check whether the condition itself excludes the rows you expected.
- Text works but numeric or date comparisons fail: Check whether the Excel column contains consistent types. Mixed numbers, text, blanks, and dates can complicate filtering; standardize the column and test representative values.
- A column name is rejected: Use the exact table header and try a simple header without punctuation or unusual spacing. Refresh the selected table if its structure changed after the action was configured.
- A combined query fails: Reduce it to one condition, then add the next condition. This helps identify unsupported operators or combinations; use Filter array as a fallback when appropriate.
Run history is often the fastest diagnostic tool. Open the failed flow run, expand the Excel action, and inspect its inputs and outputs. This can reveal whether the query text was assembled as intended, whether the action selected the right table, and whether the result was empty or truncated. A small test table with a few known rows is useful for checking syntax without risking a production process.
Frequently Asked Questions
What is the correct Filter Query syntax for Excel in Power Automate?
Use an OData-style condition in the Excel Online (Business) List rows present in a table action, such as Status eq 'Open'. Put text in single quotes and use the column header as the property name.
Can I use an Excel FILTER formula in Power Automate’s Filter Query field?
No. The field expects connector query syntax, not a worksheet formula. Use an Excel formula in a worksheet when you want results displayed in cells, or use Filter array in the flow for post-retrieval filtering.
Why does my Excel Filter Query return no rows?
Check the selected workbook and table, the exact header, the value’s data type, and whether the stored text matches your query. Inspect the action’s run history and test a basic equality query before adding more conditions.
How do I filter for more than 256 Excel rows?
Open the action’s Settings, enable Pagination, and choose a suitable threshold. Then verify the returned row count in run history; pagination does not guarantee that every workbook or connector limit is removed.
Should I use Filter Query or Filter array?
Use Filter Query for supported conditions that can narrow rows as the Excel action retrieves them. Use Filter array when you need logic the connector does not accept or when filtering an array already produced by an earlier step.
Related
- Excel Slicer Colors: How to Change and Customize Them
- Excel Slicer: Connect One Slicer to Multiple PivotTables
- Excel Shortcut to Go to a Named Range
Try it: the Formula Explainer: paste any formula and see each function and reference in plain English.
More in Formulas & functions
- Sumifs with date range?Learn how SUMIFS handles dates, boundaries, months, extra criteria, and common errors, with clear Excel examples to help…
- Excel Formula Bar Not Showing? How to Restore ItIf the formula bar is missing in Excel for Microsoft 365 on Windows, open the View tab and,…
- How to Remove Spaces in Excel With TRIM and SUBSTITUTETo clean extra spaces in Excel, use TRIM; to delete every ordinary space, use SUBSTITUTE. With the original…
- Excel Formula for Age From DOB: Years, Months, and DaysTo calculate age in completed years from a date of birth in cell A2, use =DATEDIF(A2,TODAY(),"Y"). It compares…
- Excel COUNTIF Range Examples: Text, Numbers, and DatesUse Excel’s COUNTIF function to count cells in a range that match one condition: for example, =COUNTIF(A2:A20,"East") counts…
- Excel Keep Duplicates: Remove Unique RowsTo keep every row whose value appears more than once, add a helper formula such as =COUNTIF($A$2:$A$8,A2)>1, fill…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.