Module 6 - Structured References - Excel...

16
Module 6 - Structured References TOPICS COVERED: 1) Introducing the Excel Table (0:07) 2) Using Structure References (1:55) 3) Default Table Style (2:18) 4) Distinguishing Excel Tables from Other Tables (3:59) 5) Table Names (4:30) 6) Self-Integrity - Adding Rows (5:50) 7) Self-Integrity - Adding Columns (7:21) 8) Other Methods for Adding/Deleting Rows or Columns to Excel Tables (8:18) 9) Formatting vs. Styling (10:00) 10) Structured References (11:22) 11) Structured References - Column Reference (12:40) 12) Structured References Are Absolute References (15:25) 13) Table Integrity (18:56) 14) Structured References - Shortform (21:06) 15) Structure References Support All Reference Operators (22:00) 16) Structured Reference - Header Row (22:35) 17) Structured Reference - Total Rows (23:04) 18) Structured Reference - Weakness (23:32) 19) Structured References are the Future (25:45) Introducing the Excel Table (0:07) Since Excel 2007, Microsoft has been pushing the use of a data table as an entity, called the Excel Table. The goal is to increase robustness and ease of working with lists of data. To support the Excel Table is a new way of referencing the data table called Structured References. Note that Structured References apply ONLY to Excel Table data. They do not function for normal cells, and they only work in Excel 2007 and later versions. The question becomes, if INDEX-based dynamic ranges are the fastest method of referencing data Module 6 - Structured References - 1 Discover the Next Level of Excel

Transcript of Module 6 - Structured References - Excel...

Module 6 - Structured References

TOPICS COVERED:

1) Introducing the Excel Table (0:07)2) Using Structure References (1:55)3) Default Table Style (2:18)4) Distinguishing Excel Tables from Other Tables (3:59)5) Table Names (4:30)6) Self-Integrity - Adding Rows (5:50)7) Self-Integrity - Adding Columns (7:21)8) Other Methods for Adding/Deleting Rows or Columns to Excel Tables (8:18)9) Formatting vs. Styling (10:00)10) Structured References (11:22)11) Structured References - Column Reference (12:40)12) Structured References Are Absolute References (15:25)13) Table Integrity (18:56)14) Structured References - Shortform (21:06)15) Structure References Support All Reference Operators (22:00)16) Structured Reference - Header Row (22:35)17) Structured Reference - Total Rows (23:04)18) Structured Reference - Weakness (23:32)19) Structured References are the Future (25:45)

Introducing the Excel Table (0:07)

Since Excel 2007, Microsoft has been pushing the use of a data table as an entity, called the ExcelTable.The goal is to increase robustness and ease of working with lists of data.

To support the Excel Table is a new way of referencing the data table called Structured References. Note that Structured References apply ONLY to Excel Table data. They do not function for normalcells, and they only work in Excel 2007 and later versions.

The question becomes, if INDEX-based dynamic ranges are the fastest method of referencing data

Module 6 - Structured References - 1 Discover the Next Level of Excel

tables, should you even learn Structured References. YES!

The dynamic ranges produced by Structured References are much more robust and offer much morecapability than just creating a dynamic range.

Using Structure References (1:55)

(1) Select any cell in your table(2) Press Ctrl-T (the keyboard shortcut for the Ribbon's Insert --> Table command)(3) Ensure that Excel accurately selects your data table(4) Check whether or not the table has headers(5) Click OK

This can also be achieved via the Ribbon.

Module 6 - Structured References - 2 Discover the Next Level of Excel

Default Table Style (2:18)

Excel applies the default table style (Style Medium 2). You can easily change the table style via theRibbon or you can create your own. As you mouse over the various styles, the Excel Table's style willchange.

Keep in mind, sometimes no styling is the best option and this is an option in the Table Styles menu aswell.

Module 6 - Structured References - 3 Discover the Next Level of Excel

Distinguishing Excel Tables from Other Tables (3:59)

(1) Even when no styling is present, you can easily tell if a data table is an Excel Table by the tinytriangle in the bottom-righthand corner of the last data cell in the table.This represents the bottom-righthand extent of the table.

(2) And notice that the Filter for column headers is turned on for the table by default. This can beeasily turned off via the Data --> Filter command.

Module 6 - Structured References - 4 Discover the Next Level of Excel

Table Names (4:30)

Excel will choose a default name for your table.

(1) Notice that Excel creates a named formula in the Name Manager window.(2) Notice the table icon next to the table name.(3) The "Refers to:" field is read-only (because this is managed by Excel when changes to the table aremade).

But we can change the name to anything we like so long as it follows the rules for names.A best practice is to prefix the name of the table reference with "tbl".

(4) The table name can be changed from the Table Tools tab in the Ribbon.

Module 6 - Structured References - 5 Discover the Next Level of Excel

Self-Integrity - Adding Rows (5:50)

One of the advantages of Excel Table is self-integrity. You can see this easily in the "banded rows"feature of the Excel Table.

When rows or columns are added or deleted, Excel takes the responsibility of adjusting the range thatdefines the table.

Adding rows to the table is as simple as adding data to the row just below the last row in the table. Excel automatically includes the newly added row into the table structure and reformats the tableaccordingly.

Module 6 - Structured References - 6 Discover the Next Level of Excel

Self-Integrity - Adding Columns (7:21)

You can add columns in the same way.

Since column headers play a special role in the Excel Table, Excel will provide a unique default nameto the column header. This can be easily changed by typing over this value so long as the column header you provide isunique.

Other Methods for Adding/Deleting Rows or Columns to Excel Tables (8:18)

The Tabbing MethodAs you tab to through the data using the 'Tab' key, when you reach the very last cell of the table andtab once more, Excel creates a new data row.This feature works well for quick data-entry.

Inserting Rows MethodBy inserting rows into the table.

Module 6 - Structured References - 7 Discover the Next Level of Excel

Or inserting rows in the worksheet. Since the table intersects.

Deleting rows or columns from the Table or Worksheet works in a similar fashion.And the Table range will always be updated accordingly.

Formatting vs. Styling (10:00)

With banded rows, it seems that formatting is being updated. But to clarify, this is not formatting, buttable styling.Table styling can be overrided.

Table styling is superceded by normal cell formatting. And of course, conditional formatting supercedesnormal cell formatting.

Module 6 - Structured References - 8 Discover the Next Level of Excel

Structured References (11:22)

Structured References is a way to refer to all or part of a table from a formula.

When you select all of a table's data, excluding the headers, this is the definition of a table. And therange selected will be that of the table name.

Module 6 - Structured References - 9 Discover the Next Level of Excel

Structured References - Column Reference (12:40)

The general form for the structured reference of a column is: tableName[columnName]

This is similar to what we would attempt to do with a dynamic range, but not exactly. Notice that theissue with blank cells or blank rows does not come into play at all. This is self-integrity at work. Excelknows the boundaries of the table and does not include those blanks in the CountA formula.

Note: The Structured Reference to the Country column is not defined in the Name Manager. Only thetable itself is defined.

Module 6 - Structured References - 10 Discover the Next Level of Excel

Structured References Are Absolute References (15:25)

All Structured References to special portions of a table (i.e. columns, headers, and totals) are handled outside the named manager system. This has unusual consequences.

The absolute operator ($) cannot be used on structured references at all. This is because ALLstructured references are TOTALLY absolute, and there is no way to make them relative.

There is a way to make it easier to enter these formulas when we want relative behavior by using theFILL by dragging the handle of a cell and dragging. Note that this is not really a relative reference, butjust a method for allowing relative input of formulas.

Structured Reference t cannot be used directly for: - Data Validation - Conditional Formatting - Form Controls

Fortunately, wrapping a Structured Reference in a named formula, and using the named formula getsus around these limitations!

Module 6 - Structured References - 11 Discover the Next Level of Excel

Table Integrity (18:56)

Pushing Data When a table expands, it pushes any cell-based data away that would interfere with the table. Anydependent references are automatically updated in the proper way.

Calculated ColumnsWhen a formula is entered into a blank column, the table copies the formula to every cell in that columnautomatically.

Structured References - Shortform (21:06)

Structured References to table components from within that same table do not require the table nameas a prefix.

NOTE: @ means current row, but is often not required.

Module 6 - Structured References - 12 Discover the Next Level of Excel

Structure References Support All Reference Operators (22:00)

Support all three of the reference operators (the colon, comma, and space characters). This makessense since each Structured Reference resolves to a range of actual cells.

Module 6 - Structured References - 13 Discover the Next Level of Excel

Structured Reference - Header Row (22:35)

Special keywords exist for refering to the Header and Total rows using the pound sign, #.For example, #Headers.

Module 6 - Structured References - 14 Discover the Next Level of Excel

Structured Reference - Total Rows (23:04)

The total row is inserted on the bottom of the table. All of the normal totalling functions are available tobe used.

Module 6 - Structured References - 15 Discover the Next Level of Excel

Structured Reference - Weakness (23:32)

A weakness reveals itself here. References to these rows fail when the rows are hidden.

In practice, any formulas outside of the table should do their own tally without relying on theTotals Row.This is inefficient. But it is the only way that works reliably.

Structured References are the Future (25:45)

Structured References offer powerful new capabilities and exceptional increases in model robustness.

And while INDEX formulas are, indeed, the fastest, Structured References are the future and we shouldembrace them.

Module 6 - Structured References - 16 Discover the Next Level of Excel