• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Last added column using "SUMMARIZE" throws error

jutu

Member
Hi. I have created the below DAX. It works fine but only to the point of "Order 1", but when I add the last row "Order 9" it throws error that there're too few arguments. I tried adding parenthesis and different ways but not joy if you can help please. It was working till I added the last column (order 9) but if I ommit the last added column it does work fine. Thank you

Date Periods.9Rows =
UNION(
ADDCOLUMNS(
CALENDAR(MIN('Semantic FactCommunications'[LetterSentDate]),MAX('Semantic FactCommunications'[LetterSentDate])), "Type", "Custom",
"Order", 1),
ADDCOLUMNS(
CALENDAR(MIN('Semantic FactCommunications'[LetterSentDate]),MAX('Semantic FactCommunications'[LetterSentDate])), "Type", "All Time",
"Order", 2),
ADDCOLUMNS(
DATESMTD('Semantic FactCommunications'[LetterSentDate]), "Type", "MTD",
"Order", 3),
ADDCOLUMNS(
PREVIOUSMONTH('Semantic FactCommunications'[LetterSentDate]), "Type", "Previous Month",
"Order", 4),
ADDCOLUMNS(
DATESYTD('Semantic FactCommunications'[LetterSentDate]), "Type", "YTD",
"Order", 5),
ADDCOLUMNS(
PREVIOUSYEAR(DATESYTD('Semantic FactCommunications'[LetterSentDate])), "Type", "Last Year",
"Order", 6),
ADDCOLUMNS(
DATESQTD('Semantic FactCommunications'[LetterSentDate]), "Type", "QTD",
"Order", 7),
ADDCOLUMNS(
PREVIOUSQUARTER('Semantic FactCommunications'[LetterSentDate]), "Type", "Previous QTD",
"Order", 8),
ADDCOLUMNS(
SUMMARIZE(
VALUES('Semantic FactCommunications'[LetterSentDate]),
'Semantic FactCommunications'[LetterSentDate],
"Type", "Selected Date",
"Order", 9
), [Letters Sent]))
 
You've got three summarize column names in quotes but only one expression (9), which doesn't make sense.
 
Back
Top