Dashboard Mode - SPLIT function
Goal
Split full names into first and last names automatically for easier sorting and analysis.
Split full names into first and last names automatically for easier sorting and analysis.
| Full Name | First Name | Last Name | Department | Salary |
|---|---|---|---|---|
| John Smith | John | Smith | Sales | 50000 |
| Mary Johnson | Mary | Johnson | Marketing | 55000 |
| Linda Lee | Linda | Lee | HR | 48000 |
| James Brown | James | Brown | IT | 60000 |
| Patricia Davis | Patricia | Davis | Finance | 62000 |
=INDEX(SPLIT(A2," "),1) entered in B2 and dragged down. This extracts the first name from the full name in A2.=INDEX(SPLIT(A2," "),2) entered in C2 and dragged down. This extracts the last name from the full name in A2.=SUBTOTAL(9,E2:E6) in cell E7 to show total salary of visible employees.=SUBTOTAL(1,E2:E6) in cell E8 to show average salary of visible employees.=COUNTA(UNIQUE(FILTER(D2:D6,SUBTOTAL(3,OFFSET(D2,ROW(D2:D6)-ROW(D2),0,1))))) in cell E9 to count unique visible departments.+----------------+----------------+----------------+----------------+----------------+ | Full Name (A) | First (B) | Last (C) | Dept (D) | Salary (E) | +----------------+----------------+----------------+----------------+----------------+ | John Smith | John | Smith | Sales | 50000 | | Mary Johnson | Mary | Johnson | Marketing | 55000 | | Linda Lee | Linda | Lee | HR | 48000 | | James Brown | James | Brown | IT | 60000 | | Patricia Davis | Patricia | Davis | Finance | 62000 | +----------------+----------------+----------------+----------------+----------------+ | | | | Total Salary | 275000 | | | | | Average Salary | 55000 | | | | | Dept. Count | 5 | +----------------+----------------+----------------+----------------+----------------+
Adding a filter on the Department column will update the Total Salary, Average Salary, and Department Count to reflect only the filtered employees. The First Name and Last Name columns will show split names only for visible rows.
If you add a filter to show only employees from the 'Sales' and 'IT' departments, which components update?