1. Extract Specific Columns With CHOOSECOLS
Use CHOOSECOLS to pull selected columns—and reorder them at the same time—from a wider table (1 = first column of the range, 3 = third column, -1 = last column):
=CHOOSECOLS(A2:E100, 1, 4, 2)
2. Stack Tables Vertically With VSTACK & Horizontally With HSTACK
Combine two or more matching tables top-to-bottom using VSTACK, or place ranges side-by-side using HSTACK:
=VSTACK(A2:C20, E2:G20)
=HSTACK(A2:B20, D2:E20)
Worked Example: Reordering Columns With CHOOSECOLS
Source Table (A2:D3: ID | Region | Status | Amount) |
=CHOOSECOLS(A2:D3, 1, 4, 3) Output |
|---|---|
Row 1: INV-1 | North | Paid | $500 |
Row 1: INV-1 | $500 | Paid |
Row 2: INV-2 | South | Pending | $300 |
Row 2: INV-2 | $300 | Pending |
Tips & Error Prevention
- Match column counts when stacking with
VSTACK: Keep each stacked range on the same number of columns so rows align cleanly. - Prevent
#SPILL!and#VALUE!: Clear cells where the output array expands, and avoid negative/zero column indexes that fall outside your range (which return#VALUE!). - Filter before or after shaping: Combine with FILTER or SORT + FILTER when building dynamic report views.