Перейти к содержимому
GridBelt
  • Тест по Excel
  • Упражнения
  • Программы
  • Цены
Войти
Начать бесплатный тест
  • Тест по Excel
  • Упражнения
  • Программы
  • Цены
ВойтиСоздать аккаунт
Начать бесплатный тест
GridBelt

Тренируйте навыки Excel прямо в браузере.

Тест по Excel

  • Уровень 1: Начальный
  • Уровень 2: Средний
  • Уровень 3: Продвинутый
  • Подготовка к тесту по Excel за 7 дней
  • Таблица лидеров
  • Тест по Excel на собеседовании
  • Тест по Excel от Indeed

Упражнения

  • Все упражнения
  • Программы
  • Для начинающих

Материалы

  • Формулы Excel
  • Горячие клавиши Excel

Компания

  • О проекте
  • Цены
  • Как мы проверяем

© GridBelt. Все права защищены.

  • Политика конфиденциальности
  • Условия использования
  • Политика возврата средств

Excel — товарный знак корпорации Microsoft. Indeed, TestGorilla, SHL и другие товарные знаки принадлежат их владельцам. GridBelt — независимый сайт для практики: он не связан с Microsoft, TestGorilla, SHL или Indeed, не одобрен и не спонсируется ими.

  1. Упражнения
  2. /
  3. Pivot tables

GROUPBY practice: a pivot-style sales report by region

  • Средний
  • ~6 мин
  • Pivot tables
  • Excel 365

Текст упражнения на английском

The Q3 2026 order log of a packaging distributor holds 240 orders in A2:E241, each booked to one of seven sales regions. The sales director wants the classic PivotTable — Region in Rows, Sum of Amount in Values, the grand total at the bottom. This practice grid has no PivotTable command, and in Excel 365 you do not need one: a single GROUPBY formula builds the same report and updates itself whenever an order changes. The headings are ready in G1:H1; the report starts in G2.

Что нужно сделать

  1. 1Click G2, under the headings in G1:H1 — they play the part of a PivotTable's Row Labels and Sum of Amount.
  2. 2Type =GROUPBY(C2:C241,E2:E241,SUM). The first argument is the field that goes to Rows (Region, C2:C241), the second the field that goes to Values (Amount, E2:E241), the third the summary function — SUM, written without brackets.
  3. 3Start both ranges at row 2, just below the header. Excel 365 recognises a header row by itself, but this practice grid would list the header "Region" as one more group with 0, so leave row 1 out — that works in Excel too.
  4. 4Press Enter. The regions spill down from A to Z with their totals, and the last row, labelled Total, is the grand total. Keep the cells below and to the right of G2 empty, or GROUPBY shows #SPILL!.
  5. 5Compare the Total with =SUM(E2:E241) in a spare cell such as K2: both add up every order once. Then click Check.

Ячейки ответа

Обратная связь

Введите формулу в таблицу, нажмите Enter, а затем «Проверить». Мы оцениваем значение в каждой ячейке ответа и формулу, которая его даёт.

Задания

  1. Не провереноIn G2, use GROUPBY to build the PivotTable-style report: one row per region (C2:C241) with the sum of its amounts (E2:E241), regions sorted A to Z, and the grand total row at the bottom.

Для заданий в таблице рекомендуем компьютер. Лист прокручивается внутри этой области.

StartInsertFormulasDataView
A1fxГотовим вашу рабочую книгу…
A
B
C
D
E
F
G
H
I
J
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
Sheet1

Введите формулу в лист, затем нажмите «Проверить».

Об этом упражнении

Набор данных (строк: 240) на одном листе, одна ячейка ответа, около 6 мин. Проверка прямо в браузере: значение и формула, которая его даёт, с обратной связью о том, что исправить.

Как решить

  • G2=GROUPBY(C2:C241,E2:E241,SUM)

GROUPBY does what a PivotTable does with one field in Rows and one in Values: it finds every distinct region in C2:C241, adds up the amounts of each one, sorts the labels A to Z and appends a Total row — all from one formula in G2. Because it is a formula, the report recalculates the moment an amount, a region or a whole order changes, and a region that appears in the data for the first time gets its own row; a PivotTable shows such changes only after Refresh. The Total equals SUM(E2:E241) because every order belongs to exactly one region.

Pitfall 1: #SPILL! — the result needs every cell below and to the right of G2 to be empty; a stray value or an old formula there blocks it. Pitfall 2: header rows. Excel 365 notices a header in the selection (text above numbers) and leaves it out; this practice grid treats a selected header as data and shows an extra "Region" group with 0, so start at row 2 — that works in both. Pitfall 3: whole columns (C:C, E:E) also take in the empty rows below the data, which adds a blank group with 0. Optional arguments: =GROUPBY(C2:C241,E2:E241,SUM,0,0) drops the Total row (total_depth 0), and a sort_order of -1 lists the regions Z to A. In Excel 365, sort_order -2 sorts by the amounts; this grid ignores the column number in sort_order, so wrap the result in SORT instead (the tickets-per-agent exercise shows how). The PivotTable route in Excel: Insert → PivotTable, drag Region to Rows and Amount to Values (Sum is the default for numbers), then PivotTable Analyze → Refresh after the data changes. Version note: GROUPBY needs Excel for Microsoft 365; the one-time-purchase versions (Excel 2019, 2021 and 2024) do not have it, so there you need the PivotTable or a SUMIFS block with typed labels.

Другие рабочие способы

  • =GROUPBY(C2:C241,E2:E241,SUM,0,1) — the same report with field_headers 0 and total_depth 1 typed out
  • =GROUPBY(C2:C241,E2:E241,SUM,0,1,1) — also sorting by the first column (A to Z) explicitly
  • Without GROUPBY (Excel 2019, 2021 or 2024): typed region labels, =SUMIFS($E$2:$E$241,$C$2:$C$241,G2) filled down and a SUM for the Total row — the same numbers, but not accepted here because the task asks for GROUPBY

Частые ошибки

Selecting whole columns, =GROUPBY(C:C,E:E,SUM): the empty rows below the data become an extra blank group with 0, so the report no longer matches the PivotTable; reference the data rows only.

Как мы проверяем

Принимается любая формула, которая даёт верный результат, если только задание не называет функцию: тогда другая функция даёт половину балла. Мы сравниваем значения с небольшим допуском и не учитываем регистр и пробелы в тексте. Верное число, введённое вручную вместо формулы, даёт половину балла. Задания с несколькими ячейками получают полный балл, если верны 100% ячеек, и половину — если верны от 50%. Там, где это важно, мы также меняем входную ячейку в копии вашего листа и проверяем, что формула пересчитывается правильно.

Ответы рассчитаны по правилам Excel 365 и 20 ноября 2026 г. сверены в нашей системе проверки. Автор: GridBelt team.

Входит в программы

  • Excel for Data AnalystsДень 8
  • Excel for Sales and MarketingДень 7

Похожие упражнения

  • Pivot without a pivot: revenue by category and month with SUMIFSСредний, ~10 мин
  • Tickets per agent: GROUPBY with a filter, no total, largest firstПродвинутый, ~9 мин
  • Sales by region and product with SUMIFSСредний, ~7 мин

Справка по функции

Официальная документация

Следующее упражнение

Tickets per agent: GROUPBY with a filter, no total, largest first