Sub topic 8
The @ Operator and Legacy Array Formulas
This chapter explains what the @ operator does, why Excel adds it to some formulas you didn't write, and how older Ctrl+Shift+Enter (CSE) array formulas fit into a dynamic array workbook. It assumes you already know how a formula spills, how to find the anchor cell of a spill range, and what #SPILL! means. It also assumes you can read relative and absolute references.
Implicit intersection: the old rule
Before dynamic arrays, a formula could only return one value per cell. When a formula received a range where it expected a single value, Excel quietly reduced the range to one cell. This reduction is called implicit intersection.
The rule is based on position:
- If the range is a single column, Excel uses the cell in the same row as the formula.
- If the range is a single row, Excel uses the cell in the same column as the formula.
- If the range is two-dimensional, the formula cell must fall inside it in both directions.
- If the formula cell does not line up with the range, the result is
#VALUE!.
This is why a formula such as =B2:B6*C2:C6 entered in D2 of an old workbook returned only the product for row 2. You had to fill it down to get the other rows. The same formula in dynamic array Excel returns five values and spills them. The formula text is identical. Only the calculation engine's behavior changed.
What the @ operator does
The @ operator asks for implicit intersection explicitly. It tells Excel: "reduce this to one value the old way, and do not spill."
=@A2:A6Suppose A2:A6 holds 10, 20, 30, 40 and 50. Entered in C4, this formula returns 30, the value in row 4 of the range. Entered in C8, it returns #VALUE!, because row 8 is outside A2:A6. Entered without @, the same formula in C4 would spill all five values down from C4.
@ also works on functions that can return arrays or multi-cell ranges:
=@SEQUENCE(5)Here the result is a single number, 1. When the operand is an in-memory array rather than a range, there is no row or column position to match, so Excel returns the array's first (top-left) value. If you want a specific element from an array, INDEX states your intent more clearly than @.
The diagram shows how the engine treats a range reference with and without @.
Where Excel adds @ for you
When you open a workbook created in an older version, you may see @ in formulas you never typed. Excel adds it only where the old and new engines could give different answers. It is a compatibility marker that keeps the formula's result the same as before.
Excel typically inserts @ in these cases:
- A range reference is used where a single value was expected, such as
=@A2:A6, or=B2*@C2:C6. - A function that can return a multi-cell range or an array is used in a single-value position, for example
=@INDEX(A2:A20,3)or=@OFFSET(A1,1,0,5,1). - A user-defined function (a custom function written in VBA or as an add-in) is called, because Excel cannot know whether it returns an array.
Excel does not add @ to a plain single-cell reference like =A2, or to functions that always return one value, like =SUM(A2:A6). Those behave the same in both engines.
The reverse also applies. If you type =A2:A6 in dynamic array Excel and then open the file in an old version, Excel 2019 and earlier treat it as an array formula or apply implicit intersection, depending on how the formula was saved. See the compatibility section below.
Removing @ on purpose
An @ that Excel inserted is not a defect. It preserves old behavior. You can delete it when you want the formula to spill. Do this deliberately, because the effect can be larger than it looks.
Consider a column of formulas that were filled down from D2 to D6:
=@B2:B6*@C2:C6Each formula multiplied only its own row. If you remove both @ operators from D2 and the formulas below it are still in place, D2 tries to spill five values into D2:D6. Cells D3:D6 contain formulas, so D2 returns #SPILL!. The correct cleanup is to delete D3:D6 first, then fix D2 so a single formula remains:
=B2:B6*C2:C6For a table of calculated rows where each row must stay independent, keeping a one-row-at-a-time formula is often right. In a data range with no table, a single spilling formula is usually simpler and cannot get out of sync with its neighbors.
Use this checklist before removing @:
- Confirm that the formula was meant to return one value, not a list.
- Clear any formulas or values in the cells it will spill into.
- Check whether anyone opens the file in a version without dynamic arrays.
- Check that other formulas do not rely on the single-value result, for example a lookup that expects a single number.
The other @: tables
Excel tables use @ with a different meaning. In =[@Sales]*[@Price], the @ means "this row of the table." This is a structured reference, not implicit intersection, and it is not removed or converted. Do not confuse the two. A structured reference with @ always returns one cell from the current row. A leading @ before a range or function is the implicit intersection operator.
Legacy array formulas (CSE)
Before dynamic arrays, the only way to make Excel evaluate a formula over whole arrays was to enter it with Ctrl+Shift+Enter. Excel then wrapped the formula in curly braces:
{=SUM(IF(A2:A6>0,B2:B6))}You cannot type the braces. Excel adds them to show the formula is a legacy array formula. These formulas still work in current Excel, and Excel preserves them when you open a file.
Single-cell legacy formulas
A single-cell CSE formula evaluates arrays internally and returns one result. The example above sums the values in B2:B6 where the matching A value is positive. In dynamic array Excel, you can enter that formula with plain Enter, and it calculates correctly with no braces. Old files keep the braces, but the result is the same.
Multi-cell legacy formulas
A multi-cell CSE formula was entered by selecting a block of cells first, typing the formula, and pressing Ctrl+Shift+Enter. The block holds one array formula, and it has fixed rules:
- You cannot edit or delete part of the block. Excel reports that you cannot change part of an array. You must select the whole block to edit or clear it.
- The size is fixed. If the result is bigger than the block, the extra values are cut off. If it is smaller, the leftover cells show
#N/A. - Inserting a row or column inside the block is blocked.
A spill range has none of these limits. It resizes itself, and you edit it from the anchor cell. This is the main practical reason to migrate.
Converting a legacy formula
For a single-cell formula, select the cell, press F2, and press Enter. Excel re-enters it as a regular formula, and the braces disappear. For a multi-cell block, select the whole block, copy the formula text from the top-left cell, delete the block, and enter the formula once in the top-left cell with plain Enter. It spills into the same area if the cells are free.
Check results after converting. A legacy formula that relied on implicit intersection inside a function can behave differently once it is evaluated as an array.
Comparing the three behaviors
| Behavior | How it is entered | Result size | Editing |
|---|---|---|---|
| Implicit intersection with `@` | Typed with `@`, or added by Excel | One cell | Edit like any formula |
| Legacy CSE array formula | Ctrl+Shift+Enter, shown with braces | Fixed block or one cell | Whole block only |
| Dynamic array formula | Plain Enter | Resizes automatically | Edit the anchor cell |
Compatibility and gotchas
- Older Excel shows spill formulas as CSE formulas. In Excel 2019 and earlier, a dynamic array formula appears in braces over a fixed block that matches the spill size when the file was saved. It no longer resizes.
- New functions fail in old versions.
FILTER,SORT,SORTBY,UNIQUEandSEQUENCEreturn#NAME?in versions that do not have them. Nothing in the formula can fix this. - Fill-down and
@can disagree. Copying a formula with@down a column keeps each copy independent, which is often the reason the@is there. @hides a mistake. If a formula returns a single value where you expected a list, check for a stray@before you debug the logic.
Exercises
Exercise
A1:A5 holds the numbers 5, 10, 15, 20 and 25. You enter =@A1:A5 in cell C3. What does it return, and what does it return if you move the same formula to C8?
Show answer
In C3 it returns 15, the value from row 3 of the range, because implicit intersection matches the formula's row. In C8 it returns #VALUE!, because row 8 is outside A1:A5 and there is no intersecting cell.
Exercise
A workbook has =@B2:B6*@C2:C6 filled down from D2 to D6. You delete the two @ operators from D2 only. What happens, and what is the correct way to turn this into one spilling formula?
Show answer
D2 tries to spill five results into D2:D6, but D3:D6 still contain formulas, so D2 returns #SPILL!. Delete D3:D6 first, then leave one formula in D2 without @, which is =B2:B6*C2:C6.
Exercise
Name two limits of a multi-cell legacy CSE array formula that a spill range does not have.
Show answer
A legacy block has a fixed size, so oversized results are truncated and undersized results leave #N/A cells. You also cannot edit, delete or insert inside part of the block. A spill range resizes itself and is edited from its anchor cell.