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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
XaviOV
Helper V
Helper V

Calculated rows by column with random numbers

Hello,

I have a column (AñoSemana)
with different values, and I want to calculate different values that appear in the different rows of those columns, how can I differentiate between values in the column AñoSemana?

Refards,

Xavi

Hora+FechaPreguntaPestañaAñoSemana
21/05/2020 7:52:23Filtros GAFResiduos2020-S21
21/05/2020 7:52:23Filtros GAFGAF2020-S21
21/05/2020 7:52:23Filtros GAFObservaciones2020-S21
21/05/2020 7:52:23Filtros GAFResiduos2020-S21
21/05/2020 7:52:23BUENAS PRÁCTICAS DE FABRICACIÓN 2020-S21
21/05/2020 7:52:23FotoFoto-cortado2020-S21
21/05/2020 7:52:23BUENAS PRÁCTICAS DE FABRICACIÓN 2020-S21
21/05/2020 7:52:23FotoFoto-lateral2020-S21
21/05/2020 7:52:23FotoFoto-boca2020-S22
21/05/2020 7:52:23FotoFoto-cortado2020-S22
21/05/2020 7:52:23FotoFoto-lateral2020-S22
21/05/2020 7:52:23FotoFoto-boca2020-S22
21/05/2020 7:52:23¿Hay cambio de filtro?DataKey15193138716192020-S22
21/05/2020 7:52:23¿Hay cambio de filtro?DataKey15193138716192020-S22
21/05/2020 7:52:23Toneladas filtradasToneladas2020-S22
21/05/2020 7:52:23Toneladas filtradasToneladas2020-S22
21/05/2020 7:52:23Nivel tanque LipsaDataKey15433987591492020-S22
21/05/2020 7:52:23Nivel tanque LipsaDataKey15433987591492020-S22
21/05/2020 7:52:23LíneaDataKey15084099505202020-S22
1 ACCEPTED SOLUTION
Pragati11
Super User
Super User

Hi @XaviOV ,

 

Just not clear on your requirement calculation part.

But if you are looking for extracting unique values from your column, you can use something like this:

DISTINCT(Table[AñoSemana])

Replace "Table" above with your table name.

 

If this helps and resolves the issue, appreciate a Kudos and mark it as a Solution! 🙂

 

Thanks,

Pragati

 

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

View solution in original post

5 REPLIES 5
amitchandak
Super User
Super User

@XaviOV ,The information you have provided is not making the problem clear to me. Can you please explain with an example.

Appreciate your Kudos.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi @amitchandak and  @Pragati11 

The column "AñoSemana" contains the value of YearWeek and what I want to do of the rest of the columns is calculated by each group of "AñoSemana".
For example, in the year 2019 and week 35 I have several different production lines and I want to know which ones are running in these weeks, year 2019 week 36, year 2019 week 35....
I have a column with number of line and other column with the number of these lines.

 

Regards,

 

Xavi

dax
Community Support
Community Support

Hi @XaviOV , 

I am not clear about your requirement, if possible could you please inform me more detailed information(such as your expected output and your sample data )? Then I will help you more correctly.

Please do mask sensitive data before uploading.

Thanks for your understanding and support.
Best Regards,
Zoe Zhi

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @XaviOV ,

 

One thing you can do is move your "AñoSemana" on a table visual, try bringing in other columns as summarised (Count, SUM, etc.)

 

You can try looking to few things in Power BI:

https://docs.microsoft.com/en-us/dax/groupby-function-dax

https://docs.microsoft.com/en-us/dax/summarizecolumns-function-dax

https://docs.microsoft.com/en-us/dax/earlier-function-dax

 

If this helps and resolves the issue, appreciate a Kudos and mark it as a Solution! 🙂

 

Thanks,

Pragati

 

 

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

Pragati11
Super User
Super User

Hi @XaviOV ,

 

Just not clear on your requirement calculation part.

But if you are looking for extracting unique values from your column, you can use something like this:

DISTINCT(Table[AñoSemana])

Replace "Table" above with your table name.

 

If this helps and resolves the issue, appreciate a Kudos and mark it as a Solution! 🙂

 

Thanks,

Pragati

 

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.