Symmetric Aggregates
Look & Tell: NY
March 24, 2015
SQL Aggregates are Error Prone
● When computing SUM() and AVG() in SQL its easy to
make mistakes
● Adding a join can make computations incorrect
● Difficult to track down problems
● Leads to lots of separate queries.
SQL Queries Are Relate then Aggregate
● First: Relate and Filter (JOIN and WHERE clauses)
● Second: Aggregate (SUM and GROUP BY)
LookML Combines Relate and Aggregate
● Logically, LookML combines them so aggregates are
much more generalized.
● SUM and, AVERAGE work in any query, regardless of
relationship
So What?
● Radically simplifies model building (declare measures
in their views and they just work).
● Joins don’t cause incorrect results.
● Fantastic new analytical patterns are now possible.
● Reduce the number of explores (base_views)
Patterns
● New Analytic Ratios
● Revenue and expense in the same explore
● Attribute based on analysis
● Paired behavior (i.e., bought together)
● Sloppy joined dates for trends
Upgrading Your Model
● Declare your relationship types in your joins.
● Turn it on!
Questions?

More Related Content

PPTX
How to Build a Data-Driven Company: From Infrastructure to Insights
PPTX
Data Democracy: Hadoop + Redshift
PPT
Mule Fundamentals
PPTX
Mule java part-2
PPT
Climate Change in the Media: Where have we been and where are we headed?
PPTX
Mule soa
PPT
Mule Esb Fundamentals
PPTX
Mule java part-3
How to Build a Data-Driven Company: From Infrastructure to Insights
Data Democracy: Hadoop + Redshift
Mule Fundamentals
Mule java part-2
Climate Change in the Media: Where have we been and where are we headed?
Mule soa
Mule Esb Fundamentals
Mule java part-3

Viewers also liked (15)

PPTX
Mule AMQP Connector
PPTX
Frank Bien Opening Keynote - Join 2016
PPTX
Mule Batch Filter
PPT
Mule security - jaas
PPTX
Meet Looker 4
ODP
Fetch records from mysql using mule esb
PDF
From Question to Action
PPTX
Dataiku - From Big Data To Machine Learning
PPTX
Wisdom of Crowds Webinar Deck
PPT
MULE-JAAS
PPTX
PDF
Power to the People: A Stack to Empower Every User to Make Data-Driven Decisions
PDF
Dataiku - data driven nyc - april 2016 - the solitude of the data team m...
PPTX
Aspnet core
PPTX
Agile Analytics
Mule AMQP Connector
Frank Bien Opening Keynote - Join 2016
Mule Batch Filter
Mule security - jaas
Meet Looker 4
Fetch records from mysql using mule esb
From Question to Action
Dataiku - From Big Data To Machine Learning
Wisdom of Crowds Webinar Deck
MULE-JAAS
Power to the People: A Stack to Empower Every User to Make Data-Driven Decisions
Dataiku - data driven nyc - april 2016 - the solitude of the data team m...
Aspnet core
Agile Analytics
Ad

Similar to Lloyd Tabb on Symmetric Aggregates (20)

PDF
Test_document_upload_SQL_minimum_fourteen
PPT
SQL Queries
PDF
advance-sqaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal.pdf
PPT
PHP mysql Aggregate functions
PPTX
DBMS: Week 07 - Advanced SQL Queries in MySQL
PDF
FOUNDATION OF DATA SCIENCE SQL QUESTIONS
PDF
Smarter Together - Bringing Relational Algebra, Powered by Apache Calcite, in...
PDF
Cubing and Metrics in SQL, oh my!
PPTX
database_set_operations_&_function.pptx
PPTX
Unit 5 Introduction to Oracle and Sql.pptx
PDF
Why you care about
 relational algebra (even though you didn’t know it)
PDF
Sql wksht-3
PDF
SQL Queries .pdf
PDF
CS121Lec05.pdf
PPTX
Oracle SQL - Grants, filters, groups and more
PDF
Horizontal Aggregations in SQL to Prepare Data Sets for Data Mining Analysis
PDF
Question 2B
PPTX
Case 9 and 10. SQL For Data Analysis 4.pptx
PDF
Aggregation APi in Ibexa DXP by Adam Wójs
PDF
PostgreSQL, performance for queries with grouping
Test_document_upload_SQL_minimum_fourteen
SQL Queries
advance-sqaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal.pdf
PHP mysql Aggregate functions
DBMS: Week 07 - Advanced SQL Queries in MySQL
FOUNDATION OF DATA SCIENCE SQL QUESTIONS
Smarter Together - Bringing Relational Algebra, Powered by Apache Calcite, in...
Cubing and Metrics in SQL, oh my!
database_set_operations_&_function.pptx
Unit 5 Introduction to Oracle and Sql.pptx
Why you care about
 relational algebra (even though you didn’t know it)
Sql wksht-3
SQL Queries .pdf
CS121Lec05.pdf
Oracle SQL - Grants, filters, groups and more
Horizontal Aggregations in SQL to Prepare Data Sets for Data Mining Analysis
Question 2B
Case 9 and 10. SQL For Data Analysis 4.pptx
Aggregation APi in Ibexa DXP by Adam Wójs
PostgreSQL, performance for queries with grouping
Ad

More from Looker (20)

PDF
Join 2017_Deep Dive_To Use or Not Use PDT's
PDF
Join 2017_Deep Dive_Table Calculations 201
PDF
Join 2017_Deep Dive_Table Calculations 101
PDF
Join 2017_Deep Dive_Smart Caching
PDF
Join 2017_Deep Dive_Sessionization
PDF
Join 2017_Deep Dive_Redshift Optimization
PDF
Join 2017_Deep Dive_Integrating Looker with R and Python
PDF
Join 2017_Deep Dive_Customer Retention
PDF
Join 2017_Deep Dive_Workflows with Zapier
PDF
Join2017_Deep Dive_AWS Operations
PDF
Join 2017 - Deep Dive - Action Hub
PPTX
Winning the 3rd Wave of BI
PPTX
How the economist with cloud BI and Looker have improved data-driven decision...
PPTX
Frank Bien Opening Keynote - Join 2016
PPTX
Winning with Data
PPTX
Data Stack Considerations: Build vs. Buy at Tout
PPTX
Embedding Data & Analytics With Looker
PPTX
The Three Pillars of Customer Success Analytics
PPTX
The Power of Smart Counting at The RealReal
PPTX
Creating a Single Source of Truth: Leverage all of your data with powerful an...
Join 2017_Deep Dive_To Use or Not Use PDT's
Join 2017_Deep Dive_Table Calculations 201
Join 2017_Deep Dive_Table Calculations 101
Join 2017_Deep Dive_Smart Caching
Join 2017_Deep Dive_Sessionization
Join 2017_Deep Dive_Redshift Optimization
Join 2017_Deep Dive_Integrating Looker with R and Python
Join 2017_Deep Dive_Customer Retention
Join 2017_Deep Dive_Workflows with Zapier
Join2017_Deep Dive_AWS Operations
Join 2017 - Deep Dive - Action Hub
Winning the 3rd Wave of BI
How the economist with cloud BI and Looker have improved data-driven decision...
Frank Bien Opening Keynote - Join 2016
Winning with Data
Data Stack Considerations: Build vs. Buy at Tout
Embedding Data & Analytics With Looker
The Three Pillars of Customer Success Analytics
The Power of Smart Counting at The RealReal
Creating a Single Source of Truth: Leverage all of your data with powerful an...

Recently uploaded (20)

PDF
The influence of sentiment analysis in enhancing early warning system model f...
PDF
Comparative analysis of machine learning models for fake news detection in so...
PDF
Transform-Quality-Engineering-with-AI-A-60-Day-Blueprint-for-Digital-Success.pdf
PDF
OpenACC and Open Hackathons Monthly Highlights July 2025
PDF
Credit Without Borders: AI and Financial Inclusion in Bangladesh
PDF
Transform-Your-Streaming-Platform-with-AI-Driven-Quality-Engineering.pdf
PPTX
Internet of Everything -Basic concepts details
DOCX
Basics of Cloud Computing - Cloud Ecosystem
PDF
NewMind AI Weekly Chronicles – August ’25 Week IV
PPTX
Configure Apache Mutual Authentication
PDF
“A New Era of 3D Sensing: Transforming Industries and Creating Opportunities,...
PPTX
GROUP4NURSINGINFORMATICSREPORT-2 PRESENTATION
PDF
A review of recent deep learning applications in wood surface defect identifi...
PDF
Improvisation in detection of pomegranate leaf disease using transfer learni...
PDF
Early detection and classification of bone marrow changes in lumbar vertebrae...
PDF
Consumable AI The What, Why & How for Small Teams.pdf
PPTX
Microsoft Excel 365/2024 Beginner's training
PDF
Produktkatalog für HOBO Datenlogger, Wetterstationen, Sensoren, Software und ...
PDF
STKI Israel Market Study 2025 version august
PDF
NewMind AI Weekly Chronicles – August ’25 Week III
The influence of sentiment analysis in enhancing early warning system model f...
Comparative analysis of machine learning models for fake news detection in so...
Transform-Quality-Engineering-with-AI-A-60-Day-Blueprint-for-Digital-Success.pdf
OpenACC and Open Hackathons Monthly Highlights July 2025
Credit Without Borders: AI and Financial Inclusion in Bangladesh
Transform-Your-Streaming-Platform-with-AI-Driven-Quality-Engineering.pdf
Internet of Everything -Basic concepts details
Basics of Cloud Computing - Cloud Ecosystem
NewMind AI Weekly Chronicles – August ’25 Week IV
Configure Apache Mutual Authentication
“A New Era of 3D Sensing: Transforming Industries and Creating Opportunities,...
GROUP4NURSINGINFORMATICSREPORT-2 PRESENTATION
A review of recent deep learning applications in wood surface defect identifi...
Improvisation in detection of pomegranate leaf disease using transfer learni...
Early detection and classification of bone marrow changes in lumbar vertebrae...
Consumable AI The What, Why & How for Small Teams.pdf
Microsoft Excel 365/2024 Beginner's training
Produktkatalog für HOBO Datenlogger, Wetterstationen, Sensoren, Software und ...
STKI Israel Market Study 2025 version august
NewMind AI Weekly Chronicles – August ’25 Week III

Lloyd Tabb on Symmetric Aggregates

  • 1. Symmetric Aggregates Look & Tell: NY March 24, 2015
  • 2. SQL Aggregates are Error Prone ● When computing SUM() and AVG() in SQL its easy to make mistakes ● Adding a join can make computations incorrect ● Difficult to track down problems ● Leads to lots of separate queries.
  • 3. SQL Queries Are Relate then Aggregate ● First: Relate and Filter (JOIN and WHERE clauses) ● Second: Aggregate (SUM and GROUP BY)
  • 4. LookML Combines Relate and Aggregate ● Logically, LookML combines them so aggregates are much more generalized. ● SUM and, AVERAGE work in any query, regardless of relationship
  • 5. So What? ● Radically simplifies model building (declare measures in their views and they just work). ● Joins don’t cause incorrect results. ● Fantastic new analytical patterns are now possible. ● Reduce the number of explores (base_views)
  • 6. Patterns ● New Analytic Ratios ● Revenue and expense in the same explore ● Attribute based on analysis ● Paired behavior (i.e., bought together) ● Sloppy joined dates for trends
  • 7. Upgrading Your Model ● Declare your relationship types in your joins. ● Turn it on!

Editor's Notes

  • #2: Intro yourself
  • #3: Relating is the power of SQL. Very complex relationships can be described. Its all about matrix transformation. Most people don’t understand the power of this complex relating. Its about combining multiple tables (spreadsheets) into a single spreadsheet. Aggregating is the process of taking that spreadsheet and reducing it, folding along dimensions and computing measures. Window functions are a post processing step to produce things like rank and cummulative sums, etc.
  • #4: Relating is the power of SQL. Very complex relationships can be described. Its all about matrix transformation. Most people don’t understand the power of this complex relating. Its about combining multiple tables (spreadsheets) into a single spreadsheet. Aggregating is the process of taking that spreadsheet and reducing it, folding along dimensions and computing measures. Window functions are a post processing step to produce things like rank and cummulative sums, etc.