Contact

XLOOKUP in Collabora Office: Exact, Last and Approximate Matches

Lookup Intermediate Collabora Office

Use XLOOKUP in Collabora Office Calc 26.04 with duplicate-key, missing-value and approximate-match examples, array-entry guidance and compatibility limits.

Verification status: See the evidence and test scope described in this guide. How formula examples are checked

XLOOKUP finds a position in one row or column and returns the corresponding value from another range. Its explicit missing-result argument is useful when a lookup failure is an expected part of a workflow. A search from the end also makes duplicate-key handling much clearer than an ordinary first-match lookup.

The examples below use the Collabora Office 26.04 XLOOKUP reference. Expected answers are independently derived from the displayed data. They have not been executed in Collabora Office.

Availability and version history

  • First introduced: not established by the official release-history evidence reviewed. Documentation for 26.04 demonstrates support in that documentation scope; it does not establish the first release.
  • Current documented status: supported in Collabora Office Calc 26.04 desktop Help, checked October 13, 2026. No retirement or removal is documented by this source.
  • Last supported version: no final version established. “Supported in 26.04” is not a claim that 26.04 is the last working release.
  • Platform and edition: this guide follows desktop Calc Help. A Collabora Online server or mobile app may use a different core version or interface. Confirm the installed/deployed build before relying on the examples there.
  • Native testing: not performed. The array-entry instructions below are documentation-based.

Syntax and arguments

=XLOOKUP(search_criterion; search_array; result_array; [if_not_found]; [match_mode]; [search_mode])

The labels above are shortened explanatory names for the official arguments. search_array must be one-dimensional and stay on one sheet. The return range must align with the lookup positions: when searching five rows, provide five corresponding return rows.

Argument What to supply
search_criterion The key to find. The official signature permits omission when searching for blank entries; use an explicit key for ordinary lookups.
search_array The single row or column containing keys.
result_array The aligned values or rows/columns to return.
if_not_found Optional fallback. Without one, a missing match returns #N/A.
match_mode 0 exact, -1 exact or next smaller, 1 exact or next larger, 2 wildcard, 3 regular expression. Default: 0.
search_mode 1 first-to-last, -1 last-to-first, 2 ascending binary search, -2 descending binary search. Default: 1.

Square brackets describe optional arguments; do not type them. To skip an argument while supplying a later one, preserve its semicolon position. See the official match and search mode definitions.

Array entry matters in Calc

The 26.04 reference describes returning ranges with array formulas. For a reproducible desktop test, use the array-formula entry workflow: select the intended output cell or output range, enter the formula, and confirm with Ctrl+Shift+Enter. Calc supplies enclosing braces in the formula bar; do not type the braces yourself. Do not assume Excel’s automatic spill and resizing behavior in every Collabora deployment.

For scalar examples, use one output cell. For the two-column return below, reserve two output cells. The published Help is the basis for this workflow; exact behavior still needs testing in the reader’s installed build.

Prepare a small lookup table

Enter this table in A1:D6, keeping prices numeric. Put the lookup formulas in column G or later.

Row A: SKU B: Item C: Price D: Region
1 SKU Item Price Region
2 P100 Pen 12 East
3 P200 Pad 7 West
4 P100 Pen 15 North
5 P300 Box 25 East
6 P400 Tape 5 West

Example 1: an exact price lookup

=XLOOKUP("P200";A2:A6;C2:C6;"Missing";0;1)

Expected result: 7. P200 is the second entry in the lookup range, so the corresponding second price is returned. This is a positional match, not a search for the largest price or an aggregation of several records.

Try changing P200 to P999:

=XLOOKUP("P999";A2:A6;C2:C6;"Missing";0;1)

Expected result: Missing. An explicit fallback is useful for unlisted product codes. Keep it visibly different from a genuine numeric result: replacing missing prices with zero can conceal incomplete data.

Example 2: first versus last duplicate

=XLOOKUP("P100";A2:A6;C2:C6;"Missing";0;1)
=XLOOKUP("P100";A2:A6;C2:C6;"Missing";0;-1)

Expected results: 12 and 15, respectively. The first formula chooses row 2; the reverse search chooses row 4. Neither formula proves which entry is newest. Reverse search means “last in the current range order,” so sort by an authoritative date before treating the last row as the latest record.

If you need the combined value for all P100 rows, use an aggregation such as SUMIF rather than changing the search direction.

Example 3: return the matching item and price

Select G8:H8 before entering this array formula:

=XLOOKUP("P300";A2:A6;B2:C6;"Missing";0;1)

Expected output across G8:H8: Box and 25. The result range spans two columns, so one matched row returns two values. Selecting only one output cell is not a reliable way to inspect a multi-cell result in the documented array-formula workflow.

Example 4: a threshold lookup

Enter thresholds 0, 50, 100, 200 in A11:A14 and labels Starter, Standard, Priority, Premium in B11:B14. Then use:

=XLOOKUP(120;A11:A14;B11:B14;"Below all thresholds";-1;1)

Expected result: Priority. There is no exact threshold of 120. The next smaller threshold is 100. This is useful for bands whose lower boundary is inclusive.

Using match mode 1 instead would select the next larger threshold, 200, returning Premium. Test exact boundaries such as 100 and values below the smallest threshold before adopting a banding formula.

Errors and dangerous assumptions

  • Wrong but plausible results: check range alignment and duplicate keys before investigating formatting.
  • Binary search: search modes 2 and -2 require the documented sort order. An unsorted range can give an incorrect answer without a helpful error. Linear search is the clearer default for small operational tables.
  • Wildcards and regular expressions: match modes 2 and 3 cannot be combined with binary search. Do not assume a regex written for another spreadsheet has identical behavior.
  • Unexpected fallback: compare actual key data types and spaces. A product code imported as text needs consistent handling across both sides of the lookup.
  • Blocked or partial multi-cell output: reserve the intended destination and check array entry, rather than copying Excel-specific spill instructions into Calc.

Compatibility and verification

Collabora documents this function in the COM.MICROSOFT.XLOOKUP namespace and states that it is outside OpenFormula 1.3. A file opening successfully in another app does not establish that it can recalculate the formula. For older destinations, consider an explicitly tested INDEX and MATCH construction.

For native validation, record Help → About information, locale, argument separator, entry method, and the four expected outputs above. This separates documentation-based support from a reproducible observation in a particular deployment.

Official reference