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
PBI Sept Update Carousel

Power BI September 2023 Update

Take a look at the September 2023 Power BI update to learn more.

Learn Live

Learn Live: Event Series

Join Microsoft Reactor and learn from developers.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

MPPC 2023 PBI Carousel

Power Platform Conference-Power BI and Fabric Sessions

Join us Oct 1 - 6 in Las Vegas for the Microsoft Power Platform Conference.

Top Solution Authors
Top Kudoed Authors