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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
GustavoV1
Frequent Visitor

How to created calculate columns based on slicers

Hi,

I am started to use PowerBI recently and I have a question.

Is it possible and how created a calculate column to do:

 

Using the items selected in slicer 1 and slicer 2, created a column which has the value of column "Mensual M" multiply by any factor from month of slicer 1 meanwhile values in previously month no change.

 

for the picture I would like created a column which from january and february  has the value of column "Mensual M" but March "Mensual M" * any factor.

 

Regards

 

Slicer2.jpg

2 REPLIES 2
Greg_Deckler
Super User
Super User

@GustavoV1 - Couple things. You can't do this with a calculated column, you will have to use a measure. Calculated columns are only calculated when data is refreshed so they cannot be dynamic. The other thing is that I am not understanding what you are trying to achieve exactly.

 

Not really enough information to go on, please first check if your issue is a common issue listed here: https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882

Also, please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

The most important parts are:
1. Sample data as text, use the table tool in the editing bar
2. Expected output from sample data
3. Explanation in words of how to get from 1. to 2.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

Hi @Greg_Deckler 

I follow your advice and put som information.

I have:

  • a table with monthly plan production of materials
  • a table to group material from some category called "Grupo"

What we expected

  • We want simulate scenarios with following variables
    • Fix an % of increase o decrease monthly production.
    • Fix since when (month) this increase o decrease start.
  • with this scenario we can visualize how accumulate production change in time
  • we will use slicer to choose start period and what-if slicer to choose increase o decrease.

 

also put some outcomes expected

Regards

 

Table "Grupo Materiales"

idGrupoGrupo
1Masiva
2Intermedia
3Puntual
4En Desarrollo

 

Table "Plan Producción"

ProductonombremedidaGrupoTipoene-20feb-20mar-20abr-20may-20jun-20jul-20ago-20sept-20oct-20nov-20dic-20total 2020
HAX-23Madera 3x3unidadMasivaNuevo20123551581222232871015097330531.619
HAZ-22Madera 1x3unidadMasivaExistente45382197269167296352116251301242912.709
HAX-31Madera 2x4unidadIntermediaNuevo28431535736193318286108170198472992.611
HAX-22Madera 3x4unidadEn DesarrolloNuevo21329437311578161105185194247222592.246
HAX-32Madera 4x4unidadPuntualExistente99783573873022717051162150202472.050
HAX-44Madera 2x2unidadIntermediaExistente27441104611921048839473393641011.754
HAX-54Madera 2x6unidadEn DesarrolloNuevo325227259264388371582631953231562302.825
HAX-65Madera 4x5unidadPuntualNuevo541092811925747302396380731933992.357

 

Visualization expected:

 

outcome 1.jpgoutcome 2.jpg

 

 

 

 

 

 

 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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