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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Josef
Helper I
Helper I

Data model from flat SCV file in Power BI Desktop

Hi guys, 

 

I'm still fairly new to Power BI and I run into a problem that I cannot solve by myself. Also not after doing a lot of research on the internet. 

 

It concerns this situation: I created an SCV export from an energy system with multiple divices, that looks like the next example data. The devices have simular signals, but the signals are in different columns:

CSV export data

DateTemperature - Device 1Wind - Device 1Temperature - Device 2Wind - Device 2
01-01-2016,514,216,416,9
02-01-2015,215,815,315,1
03-01-2013,112,213,512,8

 

My end goal is to create a table/overview with the device and wind per date, something like this:

DateDeviceWind
01-01-20Device 114,2
01-01-20Device 216,9
02-02-20Device 115,8
02-02-20Device 215,1

 

To be able to do this, I already made a copy of the table, split it into 2 different tables and change the column names:

 

Device 1

DateTemperatureWind
01-01-2016,514,2
02-01-2015,215,8
03-01-2013,112,2

 

Device 2

DateTemperatureWind
01-01-2016,416,9
02-01-2015,315,1
03-01-2013,512,8

 

Also I created this 'Devices' table by hand

Devices

DeviceIdTitle
1Device 1
2Device 2

 

If I'm not wrong, the final table should look something like this, where the deviceId is connected to the devices table:

DateDeviceIdTemperatureWind
01-01-20116,514,2
01-01-20216,416,9
02-01-20115,215,8
02-01-20215,315,1
03-01-20113,112,2
03-01-20213,512,8

 

Is this correct? And how can I achieve this in Power BI Desktop?

Any help is greatly appreciated! Many thanks in advance. 

 

3 ACCEPTED SOLUTIONS
amitchandak
Super User
Super User

@Josef , Unpivot should help

refer : https://radacad.com/pivot-and-unpivot-with-power-bi

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

View solution in original post

V-lianl-msft
Community Support
Community Support

Hi @Josef ,

 

You can follow these steps in the power query editor:

1.Select the date column and unpivot other columns

test_0313_unpivot.PNG

2.Split the column by "-"

test_0313_split.PNG

test_0313_split2.PNG

 

Best Regards,
Liang
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

@V-lianl-msft & @amitchandak many thanks for your reply! I'm tried the unpivod option, but this didn't get the desired result for me.

 

I not sure if it is the most efficient way, but I did the following what solved the issue for me:

 

I copied the table two times. In the first copy I only kept the columns of device 1 and in the second only for device 2. Then 1 added a custom column 'deviceId' to both tables, for device 1 I put '1' in the custom column and for device two '2'. 

 

Then I merge the two tables with Compbine > Append Queries as New, to create a new table where all the device data has the same columns, and the data from each device is distinguishable from each other by the deviceId. 

 

For me the issue is now solved. Again many thanks for your replies!

View solution in original post

5 REPLIES 5
V-lianl-msft
Community Support
Community Support

Hi @Josef ,

 

You can follow these steps in the power query editor:

1.Select the date column and unpivot other columns

test_0313_unpivot.PNG

2.Split the column by "-"

test_0313_split.PNG

test_0313_split2.PNG

 

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

@V-lianl-msft & @amitchandak many thanks for your reply! I'm tried the unpivod option, but this didn't get the desired result for me.

 

I not sure if it is the most efficient way, but I did the following what solved the issue for me:

 

I copied the table two times. In the first copy I only kept the columns of device 1 and in the second only for device 2. Then 1 added a custom column 'deviceId' to both tables, for device 1 I put '1' in the custom column and for device two '2'. 

 

Then I merge the two tables with Compbine > Append Queries as New, to create a new table where all the device data has the same columns, and the data from each device is distinguishable from each other by the deviceId. 

 

For me the issue is now solved. Again many thanks for your replies!

Hello @Josef,

I'm glad you solved your problem.
Please accept the answers that make sense as a solution to your question so that people who may have the same question can get the solution directly.

Best regards
Liang
If this post helps, please consider accepting it as the solution to help other members find it more quickly.

Hi @Josef ,

 

It's glad that you have solved your problem.
Please accept the replies making sense as solution to your question so that people who may have the same question can get the solution directly.

 

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

amitchandak
Super User
Super User

@Josef , Unpivot should help

refer : https://radacad.com/pivot-and-unpivot-with-power-bi

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

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors