The basics of table calculations

Table calculations make it easy to create on-the-fly metrics. They are similar to formulas found in spreadsheet tools like Excel. Table calculations appear as green columns in the data table, rather than as blue columns (dimensions) or orange columns (measures).

Table calculations can perform mathematical, logical (true/false), lexical (text-based), and date-based calculations on the dimensions, measures, and other table calculations in your query. The formulas that you use to execute these calculations are called Centricity expressions.

Table calculations are different from regular fields

Although table calculations are similar to dimensions and measures, there are some important differences:

  • Table calculations give anyone the ability to create new fields, as opposed to regular fields, which require that you have development permissions and understand LookML.

  • Table calculations operate on the results from your query, as opposed to regular fields, which are part of the query itself. In other words, you’ll select a set of dimensions and measures and run your report as normal, then you can base table calculations on the data in that report.

  • Although table calculations are simpler and quicker to create than regular fields, they are not as easily controlled as regular fields. Since any user can create a table calculation, they might not be the “official” calculations. Keep this tradeoff in mind as you decide between regular fields and table calculations, since Centricity leverages LookML to maintain a single source of truth.

Table calculation fields appear next to dimensions and measures in the table. If you want to reuse your table calculations in the future, be sure to save your Look or copy the table calculation formula into another document.

Continue on to the next page to learn more about creating and sorting table calculations.



 

 

More questions about Centricity? Check out our website or talk to our Support Team.