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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
feralvarez994
Helper II
Helper II

Group by another table

Hi everyone! I have a table with number of records (phone calls) by employee and want to group it by another table that have the ranges

The first table contains the employees that i need, the position and the user key in different systems

feralvarez994_1-1657039940323.png

The second table contains the month/year, the employee key number (related to Identificador_Anura) and the number of calls that every employee have made per month

feralvarez994_2-1657039965979.png

The lastone contains the position, the month/year (Mes/Año) and the range of calls depending on the position (0 - 200, 201 - 300, 301 - 9999, etc)

feralvarez994_0-1657039929084.png

 

I need to multiply the number of calls per employee with the "valor" column in the last table depending on the range that goes between "Cantidad desde" and "Cantidad hasta"

 

Can someone help me? Thanks a lot!

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

HI @feralvarez994,

You can add a calculated column to the second table to lookup values from the third table based on the current 'calls' value:

Result =
CALCULATE (
    MAX ( Table3[valor] ),
    FILTER (
        Table3,
        Table3[Cantidad desde] <= EARLIER ( Table2[Calls] )
            && Table3[Cantidad hasta] >= EARLIER ( Table2[Calls] )
    )
) * Table2[Calls]

Regaeds,

Xiaoxin Sheng

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

HI @feralvarez994,

You can add a calculated column to the second table to lookup values from the third table based on the current 'calls' value:

Result =
CALCULATE (
    MAX ( Table3[valor] ),
    FILTER (
        Table3,
        Table3[Cantidad desde] <= EARLIER ( Table2[Calls] )
            && Table3[Cantidad hasta] >= EARLIER ( Table2[Calls] )
    )
) * Table2[Calls]

Regaeds,

Xiaoxin Sheng

tamerj1
Super User
Super User

Hi @feralvarez994 

can you please share a screenshot of the visual and explain further the expected results. Also is there any relationship connecting the 3rd table?

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.