Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
romilv1
Helper I
Helper I

How do I concat 2 different columns and then bring out latest record?

Hi

I have a very odd request in Power BI dashboard. We have report that fetches customer feedback score and the idea is to bring out the latest score everytimes a customer gives feedback. If customer gives 3 feedback in one quarter, the latest one should show up on report.


For example

 

 

This is the dashboard. Content hidden due to data privacy. As you can see one customer has given 2 feedbacks in quarter but both of the feedback appear in the dashboard. 

 

Have written DAX in my older reports

 

Step 1: Concact Full name & Quarter

Nm_Qtr=

CONCATENATE

('Tbl Name'[Fullname],'Tbl Name'[YearQuarter])

 

Step 2:  Do a row check

Row_Check =

ROWNUMBER

(

ORDERBY

(table 2[Createdon], DESC),

PARTITIONBY

([Nm_Qtr]))

 

We have date table (dim date ) that can join with feedback_created_dt and can bring latest feedback for the quarter (selected by user). Feedback_Created_Dt is one of the columns in fact table.

 

Question is: How to write DAX query to bring in most recent feedback in Quarter?

5 REPLIES 5
v-sathmakuri
Community Support
Community Support

Hi @romilv1 ,

 

I hope this information proves helpful. Feel free to reach out if you have any further questions or would like to discuss this in more detail. If responses provided answers your question, please accept it as a solution so other community members with similar problems can find a solution faster.

 

Thank you.

v-sathmakuri
Community Support
Community Support

Hi @romilv1 ,

 

I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. If my response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.

 

Thank you !!

v-sathmakuri
Community Support
Community Support

Hi @romilv1 ,

 

Thank you for reaching out to Microsoft Fabric Community.

Thank you @danextian  and @Deku  for prompt response.

 

May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.

Thank s & Regards,

Rekha,

CustomerSupportTeam.

danextian
Super User
Super User

Hi @romilv1 

 

Try either

LatestFeedbackScore = 
VAR LatestDate = 
    CALCULATE(
        MAX(FeedbackTable[FeedbackDate]),
        ALLEXCEPT(FeedbackTable, FeedbackTable[CustomerID], FeedbackTable[Quarter])
    )
RETURN 
    CALCULATE(
        SELECTEDVALUE(FeedbackTable[FeedbackScore]),
        FeedbackTable[FeedbackDate] = LatestDate
    )
LatestFeedbackScore TopN = 
VAR LatestFeedback =
    TOPN (
        1,
        FILTER (
            ALL ( FeedbackTable ),
            FeedbackTable[CustomerID] = SELECTEDVALUE ( FeedbackTable[CustomerID] )
                && FeedbackTable[Quarter] = SELECTEDVALUE ( FeedbackTable[Quarter] )
        ),
        FeedbackTable[FeedbackDate], DESC
    )
RETURN
    MAXX ( LatestFeedback, FeedbackTable[FeedbackScore] )

danextian_0-1741689134315.png

Please see the attached sample pbix.

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
Deku
Super User
Super User

Year QuarterNameFeedback
2025-01Tom

some feedback 

2025-02Tomand more

 

If you want to get something like in the above

 

Feedback =
MAXX( 
   TOPN( 1, table, table[date], desc )  -- return the most recent row
   , table[Feedback]                    -- return most recent row's feedback
)

 

 


Did I answer your question?
Please help by clicking the thumbs up button and mark my post as a solution!

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors