DAX MAXX Function In LuckyTemplates – Discover Last Date

I’m going to share a quick and efficient formula around the DAX MAXX function in LuckyTemplates. In this example calculation, I’ll show you how to find the last date something occurred using MAXX, which is an iterating function. You may watch the full video of this tutorial at the bottom of this blog.

I’ve seen a lot of people asking about this on the . A big part of it is just understanding what an iterating function enables you to do.

In this tutorial, I have a simple survey data, wherein the same customer/person can take a survey several times. And what we want to work out is when was the last date that someone actually took the survey.

DAX MAXX Function In LuckyTemplates – Discover Last Date

I’ve done this in a calculated column (the Max Date in the table above), but I’ll show you how to do it in a measure. I personally think that it’s easier and much better in a measure.

This is just one scenario, one example of data. The same technique can be used in many ways and I want you to think more broadly around how this technique could be used.

Table of Contents

Using DAX MAXX In A Measure

Looking at the formula below, the first thing to work out in this particular context is the variable, VAR CurrentName, which is the name of the person or customer.

DAX MAXX Function In LuckyTemplates – Discover Last Date

Then, work through a virtual table, where we can look through every line of the survey data table, but filter that virtual table by just the survey results for the current name.

So, as you can see in the Name and Max Survey Date table, it’s showing the specific name of the person for each date. So we’re basically getting a virtual table of only the surveys that each person took.

Because it’s wrapped inside MAXX, it’s going to just return one result, the max result, which is going to be the Date Taken. So, we’re going to get one date, which just shows when a person took the survey last.

Other Ways To Use The MAXX Formula Pattern

There are a lot of derivatives around this formula. For example, you wanted to find out the date that is seven days before the last time someone did something (such as purchase or pay, etc.). You could just add some metrics within the actual iterating function itself. So in this case, I added – 7. And you’ll see that the results changed to seven days before.

DAX MAXX Function In LuckyTemplates – Discover Last Date

You could even take this farther. All you need to do is probably turn this MAXX formula into a variable. So you would get the Max Date, but then you would filter the virtual table, not only by name, but also make sure all the dates are before the Max Date. That would give you the Max Date of the date prior to the Max Date.

DAX MAXX Function In LuckyTemplates – Discover Last Date

There are so many ways that you can utilize this technique to get some Max or even Min. You could flip this around and use MINX as well.

And what’s interesting here is that you can reuse or place this formula pattern into a different context to find many other insights. For example, if you look at the table below, which is a breakdown of every single time the people took the survey, but you can still see when the next survey date was.

DAX MAXX Function In LuckyTemplates – Discover Last Date

And then from there, you could probably create another measure, which is Days From Last Taken. This way, you won’t need to do this in a calculated column.

DAX MAXX Function In LuckyTemplates – Discover Last Date


Using The MAXX DAX Function In LuckyTemplates To Calculate Recent Values In Your Data
Last Purchase Date in LuckyTemplates: When Did Your Customers Make Their Last Purchase?
Working With Iterating Functions In DAX

Conclusion

The examples that I’ve demonstrated in this tutorial show you why you don’t need to create calculated columns. You can do this all within a measure very easily. I hope that you can see how the DAX MAXX formula pattern works and that you can implement it in your own business analysis and reports.

If you want to know more about this LuckyTemplates DAX MAXX function or how iterating functions work, check out the links below and my other tutorial videos on this topic. Using these functions is an absolutely crucial concept to use in power BI, especially when using DAX formulas.

Cheers!

Leave a Comment

Excel Hücrelerini Metne Sığdırma: 4 Kolay Çözüm

Excel Hücrelerini Metne Sığdırma: 4 Kolay Çözüm

Excel hücrelerini metne sığdırmak için güncel bilgileri ve 4 kolay çözümü keşfedin.

Bir Excel Dosyasının Boyutu Nasıl Küçültülür – 6 Etkili Yöntem

Bir Excel Dosyasının Boyutu Nasıl Küçültülür – 6 Etkili Yöntem

Bir Excel Dosyasının Boyutunu Küçültmek için 6 Etkili Yöntem. Hızlı ve kolay yöntemler ile verilerinizi kaybetmeden yer açın.

Pythonda Self Nedir: Gerçek Dünyadan Örnekler

Pythonda Self Nedir: Gerçek Dünyadan Örnekler

Python'da Self Nedir: Gerçek Dünyadan Örnekler

Rde Bir RDS Dosyası Nasıl Kaydedilir ve Yüklenir

Rde Bir RDS Dosyası Nasıl Kaydedilir ve Yüklenir

R'de bir .rds dosyasındaki nesneleri nasıl kaydedeceğinizi ve yükleyeceğinizi öğreneceksiniz. Bu blog aynı zamanda R'den LuckyTemplates'a nesnelerin nasıl içe aktarılacağını da ele alacaktır.

İlk N İş Günü Tekrar Ziyaret Edildi – Bir DAX Kodlama Dili Çözümü

İlk N İş Günü Tekrar Ziyaret Edildi – Bir DAX Kodlama Dili Çözümü

Bu DAX kodlama dili eğitiminde, GENERATE işlevinin nasıl kullanılacağını ve bir ölçü başlığının dinamik olarak nasıl değiştirileceğini öğrenin.

LuckyTemplatesda Çok İş Parçacıklı Dinamik Görsel Tekniği Kullanarak Öngörüleri Sergileyin

LuckyTemplatesda Çok İş Parçacıklı Dinamik Görsel Tekniği Kullanarak Öngörüleri Sergileyin

Bu eğitici, raporlarınızdaki dinamik veri görselleştirmelerinden içgörüler oluşturmak için Çok Kanallı Dinamik Görseller tekniğinin nasıl kullanılacağını kapsayacaktır.

LuckyTemplatesda İçeriği Filtrelemeye Giriş

LuckyTemplatesda İçeriği Filtrelemeye Giriş

Bu yazıda, filtre bağlamından geçeceğim. Filtre bağlamı, herhangi bir LuckyTemplates kullanıcısının başlangıçta öğrenmesi gereken en önemli konulardan biridir.

LuckyTemplates Çevrimiçi Hizmetindeki Uygulamaları Kullanmak İçin En İyi İpuçları

LuckyTemplates Çevrimiçi Hizmetindeki Uygulamaları Kullanmak İçin En İyi İpuçları

LuckyTemplates Apps çevrimiçi hizmetinin çeşitli kaynaklardan oluşturulan farklı raporların ve içgörülerin yönetilmesine nasıl yardımcı olabileceğini göstermek istiyorum.

Fazla Mesai Kâr Marjı Değişikliklerini Analiz Edin - LuckyTemplates ve DAX ile Analitik

Fazla Mesai Kâr Marjı Değişikliklerini Analiz Edin - LuckyTemplates ve DAX ile Analitik

LuckyTemplates'da ölçü dallandırma ve DAX formüllerini birleştirme gibi teknikleri kullanarak kâr marjı değişikliklerinizi nasıl hesaplayacağınızı öğrenin.

DAX Studioda Veri Önbellekleri İçin Materyalleştirme Fikirleri

DAX Studioda Veri Önbellekleri İçin Materyalleştirme Fikirleri

Bu öğreticide, veri önbelleklerini gerçekleştirme fikirleri ve bunların DAX'ın sonuç sağlama performansını nasıl etkilediği tartışılacaktır.