CONTACT US: 778-373-4422 | info@mackenziemackenzie.com


Photo by athree23 from Pixabay

How to Use percentile_cont in TSQL to Group Data by Upper, Middle, and Lower Thirds

03-September-2020
In this episode, we’re going to learn how to assign a percentile group to each record in our table, so that we can see if the record is in the upper, middle, or lower rank of its set. We’ll use climate change data from the Work Bank Group, choosing three measures to analyze. These will include (a.) percentage of land lower than 5m, (b.) annual rainfall, and (c.) population. With these, we’ll be able to see which countries are in the top, middle, and lower 33% of all countries. This is great for pre-loading calculations for data warehouse tables. In many cases it is more convenient to perform these calculations BEFORE we load them into our analytics datasets in Power BI, Tableau, SSRS, or other tools. Performance of queries or calculations is generally faster on SQL Server, and sometimes it is just more convenient to have some calculations ready before analysis begins.



Doing analytics on SQL Server? Contact me today!

3 Reasons Why You Should Learn Data Techniques

Find 3 big reasons why you should learn data techniques if you are a professional or business person.

Read article

About our workshop

The Professional Problem, 3 Things They Need, and 1 They Don't Have

Why do people constantly run into problems with their data, even when they are highly trained in their area?

Read article

About our workshop

Why Finding Uniqueness is the Key: 6 Methods to Help

Find out why keys and uniqueness are so important for data transformation and data analysis.

Read article

About our workshop

When to Excel and When Not To: Why Specialists Don't Use Excel for Data Transformations

Start your journey in data transformation, and learn why specialists don't use Excel to transform raw data for analysis.

Read article

About our workshop