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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
roger360
Frequent Visitor

Getting Syntax Error: Invalid Token, Line 3, Offset2, .

TopTeam =
VAR TopTeamTable =
    ADDCOLUMNS(
        SUMMARIZE(
            FILTER(
                Table15924,
                NOT(ISBLANK(Table15924[Redirection to?]))
            ),
            Table15924[Redirection to?]
        ),
        "Count", COUNTROWS(Table15924)
    )
VAR MaxCount = MAXX(TopTeamTable, [Count])
RETURN
    CALCULATE(
        FIRSTNONBLANK(Table15924[Redirection to?], 1),
        FILTER(TopTeamTable, [Count] = MaxCount)
    )


Th above new measure is to find the most frequest team where the calls were redirected to, excluding the blank cells. Getting the following error message. Please help! Let me know if you need any further details.

roger360_0-1744223390319.png

 



1 ACCEPTED SOLUTION
rohit1991
Super User
Super User

Hi @roger360 ,
Here’s a corrected version of your measure:

TopTeam = 
VAR TopTeamTable =
    ADDCOLUMNS(
        SUMMARIZE(
            FILTER(
                Table15924,
                NOT(ISBLANK(Table15924[Redirection to?]))
            ),
            Table15924[Redirection to?]
        ),
        "Count", CALCULATE(COUNTROWS(Table15924))
    )
VAR MaxCount = MAXX(TopTeamTable, [Count])
RETURN
    CALCULATE(
        FIRSTNONBLANK(Table15924[Redirection to?], 1),
        FILTER(TopTeamTable, [Count] = MaxCount)
    )
 

Did it work? ✔ Give a Kudo • Mark as Solution – help others too!

View solution in original post

6 REPLIES 6
v-nmadadi-msft
Community Support
Community Support

Hi @roger360 ,

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 our responses has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.


Thank you.

v-nmadadi-msft
Community Support
Community Support

Hi @roger360 

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 you.

 

rohit1991
Super User
Super User

Hi @roger360 ,
Here’s a corrected version of your measure:

TopTeam = 
VAR TopTeamTable =
    ADDCOLUMNS(
        SUMMARIZE(
            FILTER(
                Table15924,
                NOT(ISBLANK(Table15924[Redirection to?]))
            ),
            Table15924[Redirection to?]
        ),
        "Count", CALCULATE(COUNTROWS(Table15924))
    )
VAR MaxCount = MAXX(TopTeamTable, [Count])
RETURN
    CALCULATE(
        FIRSTNONBLANK(Table15924[Redirection to?], 1),
        FILTER(TopTeamTable, [Count] = MaxCount)
    )
 

Did it work? ✔ Give a Kudo • Mark as Solution – help others too!
Deku
Super User
Super User

Try this

 

TopTeam =
VAR TopTeamTable =
ADDCOLUMNS(

Filter(

ALL(Table15924[Redirection to?]),

Not ISBLANK(Table15924[Redirection to?])

),
"@Count", CALCULATE(COUNTROWS(Table15924))
)

Return

MAXX( 
TOPN(1, TopTeamTable, [@Count], DESC),

Table15924[Redirection to?]

)


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

Its showing error:

roger360_0-1744508849002.png

 

Added a missing comma, need on row 11 on your image


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

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors