The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I have a problem when trying to delete duplicate customers, the topic is the following, I have users but I need to have only one row per user and next to it the date of their LAST login, I did this but it gives me the following error:
" The expression refers to several columns. You can't convert multiple columns to a scalar value. "
Solved! Go to Solution.
Hey
This type of transformation is best done using PowerQuery - you can check this guide for more details: https://exceleratorbi.com.au/remove-duplicates-keep-last-record-power-query/
The reason that you get the error above is that SUMMARIZE will return a TABLE (which can contain more than one value per cell in the column). To fix this, you can either create a new TABLE instead of a new column, or you will need to aggregate the table to only return a value if the client is the latest (e.g. MAX([date], or something like that)
Hey
This type of transformation is best done using PowerQuery - you can check this guide for more details: https://exceleratorbi.com.au/remove-duplicates-keep-last-record-power-query/
The reason that you get the error above is that SUMMARIZE will return a TABLE (which can contain more than one value per cell in the column). To fix this, you can either create a new TABLE instead of a new column, or you will need to aggregate the table to only return a value if the client is the latest (e.g. MAX([date], or something like that)
User | Count |
---|---|
78 | |
74 | |
42 | |
32 | |
28 |
User | Count |
---|---|
104 | |
93 | |
52 | |
50 | |
46 |