cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Alirezam
Helper V
Helper V

Changing column name in a table

So, here is my problem at the moment: 

I have a table reading data from a csv file coming from an email daily. The column names might keep changing day today and I need to apply a multiplier to the values when the column changes (e.g. in this case, the data under MWh should be multiplied by 1000). How can I separate these tables based on two types of columns? or how can I apply this calculation only when the column is one of these two types? the number of rows every day is the same (24 rows) I want to make this in Power Query not DAX. Many thanx

 

Alirezam_0-1628044233889.png

 

1 ACCEPTED SOLUTION
v-stephen-msft
Community Support
Community Support

Hi @Alirezam ,

 

1.Split column by custom delimiter

1.png2.png

3.png

 

2.Use fill down in both columns

4.png5.png

 

3.Add the following custom columns

6.png7.png

8.png

 

 

Best Regards,

Stephen Tao

 

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

View solution in original post

2 REPLIES 2
v-stephen-msft
Community Support
Community Support

Hi @Alirezam ,

 

1.Split column by custom delimiter

1.png2.png

3.png

 

2.Use fill down in both columns

4.png5.png

 

3.Add the following custom columns

6.png7.png

8.png

 

 

Best Regards,

Stephen Tao

 

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

lbendlin
Super User
Super User

Do you have individual columns per location?  You will want to avoid that. 

 

You can split the column with the kWh/MWh and then fill down on the second column.

Helpful resources

Announcements
September Update

Check it Out!

Click here to learn more about the September 2022 updates!

Power BI Show Episode 10 Recap

The Power BI Community Show

Watch the playback when Amit Chandak, a Power BI Super User, demos how to use Field Parameters to make reports more dynamic.

Power BI Dev Camp Session 26

New Date - Check it Out!

Mark your calendars and join us on Thursday, October 6 at 11a PDT for a great session with Ted Pattison!

Health and Life Sciences Power BI User Group

Health and Life Sciences Power BI User Group

Power BI specialists at Microsoft have created a community user group where customers in the provider, payor, pharma, health solutions, and life science industries can collaborate.

Top Kudoed Authors