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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Diego_Vialle
Helper II
Helper II

DAX - Add column referring to a measure.

Hello, I need to add the values that are marked in the column to the side. The column "New Bimonthly Customers" derives from a measure created:

 

Diego_Vialle_0-1650068896561.png

 

Diego_Vialle_1-1650068988653.png

 

Novos Clientes Bimestrais =
VAR AllOldCustomers =
CALCULATETABLE (
VALUES ( SBOPRODMS[Nome do PN] ),
SBOPRODMS,
SBOPRODMS[Data NF]
< TODAY () - 60,
SBOPRODMS[Documento] = "Nota fiscal de saída"
)
VAR AllNewCustomers =
CALCULATETABLE (
VALUES ( SBOPRODMS[Nome do PN] ),
SBOPRODMS[Data NF]
< TODAY () ,
SBOPRODMS[Documento] = "Nota fiscal de saída"
)
RETURN
COUNTROWS ( EXCEPT ( AllNewCustomers, AllOldCustomers ) )
1 ACCEPTED SOLUTION
tamerj1
Super User
Super User

Hi Diego 

Not sure if I fully understand but you may try this

Valor Clientes Bimestrais =
SUMX (
    VALUES ( SBOPRODMS[Nome do PN] ),
    IF ( [Novos Clientes Bimestrais] = 1, [Valor NET | NF] )
)

 

View solution in original post

4 REPLIES 4
tamerj1
Super User
Super User

Hi Diego 

Not sure if I fully understand but you may try this

Valor Clientes Bimestrais =
SUMX (
    VALUES ( SBOPRODMS[Nome do PN] ),
    IF ( [Novos Clientes Bimestrais] = 1, [Valor NET | NF] )
)

 

Perfect. Is correct !! I will use the same for New Semiannual Customers.

I was wrong when using the Bimonthly New Customers measure within SUMX. It was giving placeholder error.

I have another question, but I'll open it in another message here on the forum. Thank you one more time.

 

Diego_Vialle_0-1650107428310.png

 

Diego_Vialle_1-1650107476609.png

 

tamerj1
Super User
Super User

Hi @Diego_Vialle 

what do you mean by "add to the side"?

Add up according to the clients that are marked as bimonthly. Sorry, I use google translate

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors