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
Anonymous
Not applicable

Create new table from existing table with new rows conditionned by aggregation

Hey,

Was a bit difficult to explain the problem in the Subject, sorry if it's not clear enough.

I have an existing (working) table in wich I have :
- date
- ISO week number (WEEKNUM with parameter 21)
- year & week
- rolling period : a period from 4 weeks BEFORE the current week (+ date of the monday of this week) to 4 weeks AFTER the current week (+ date of the monday of this week)
- ISO week number of the beginning of the rolling period
- ISO week number of the end of the rolling period
Its working pretty fine

a_calendrier.png

 

Now, I want a new table containing :
- the rolling period
- all the weeks between the begenning and the end of the rolling period
I don't have any idea how to get this using DAX... 🤔

a_calendrier 2.png

Could any one give me a hand on this please ?

1 ACCEPTED SOLUTION
Anonymous
Not applicable
5 REPLIES 5
Anonymous
Not applicable
Anonymous
Not applicable

HI @Anonymous ,

 

I dont know if I understood your questions.

 

But if you want to have a new table from the existing table with only the 2 columns you mentioned than folows these steps.

 

- Edit queries

-Right click on your existing table and hit on duplicate

- once you have this new duplicate table, keep the columns you want in your new table and get rid of the other columns.

 

Hope this helps!

 

Thanks,

Tejaswi

Anonymous
Not applicable

Hey @Anonymous ,

The table is already a DAX generated table, and I don't want a simple copy of it, if you take a look, for a rolling period there is just 1 week number.

What I want is :

1) get all distinct rolling period

2) for each rolling period, get all the week number that are between the starting and ending week (of the rolling period)

 

Is it clearer?

Anonymous
Not applicable

HI @Anonymous ,

 

I am still not very much clear.

 

would it be possible to give us some sample data?

 

May be show us input data and output you would like to have.

 

 

Thanks,

Tejaswi

Anonymous
Not applicable

Hey @Anonymous ,

 

The 1st image is the input data (generated table), and the 2nd image is the desired output.
For each distinct occurs of Rolling period, I want all the weeks between the startign and ending weeks of it.

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.