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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
yodha
Helper IV
Helper IV

Un-Pivoting Data issues

 

Hi, i have data in Excel file and i want to un-pivot it, to change columns to rows, but am unable to do it as expected

 This is my excel File,
Untitled 1.png

and i have un-pivoted it in power bi like this,

Untitled 2.png

and fianlly i have created a graph like this,

Untitled 3.png

 but here in this graph same BD value is coming continuously for some time (please check in tooltip in PBIX), where as ID values are changing, i need BD values also to change like ID values. Please help me with this,

Am adding dropbox links of both data and Pbix file for reference.

https://www.dropbox.com/s/w22247o4voskhuo/sample%20file.pbix?dl=0

https://www.dropbox.com/s/38oyluiwz94ams9/Power%20Bi%20data.xlsx?dl=0

 

Thanks in Advance.

1 ACCEPTED SOLUTION

There you go @yodha :

yodha_01.JPG

yodha_03.JPG

With pleasure

PBIX ,

Hope it helps

 

Regards

View solution in original post

8 REPLIES 8
YJ
Resolver II
Resolver II

Hi,

what do you mean by " i need BD values also to change like ID values."?

From what i see your axis is Date DB1 ID1, Date DB1 ID10, Date DB1 ID2 etc etc so yes the BD would not change until it changes.

What do you wnat to see in your X axis? (Date DB1 ID1, Date DB2 ID2 ) or (Date Sum(All DB), Date Sum(All ID) ??

 

regards

 

Thanks for the reply and i want to see in X axis like this (Date BD1 ID1, Date BD2 ID2, Date BD3,ID3, etc.., ) 

lc_finance
Solution Sage
Solution Sage

Hi @yodha ,

 

 

Is there a reason to unpivot separately the ID and BD columns?

What if you unpivot them together, does the chart work in that case?

 

Unpivoting them together means you will have the following columns:

- date

- attribute (both ID and BD)

- value (both ID and BD)

 

if you need a way to separate ID from BD you can create one more column using the Text.Start M formula. You can find more info on that here.

 

Let me know if this helps you.

 

Regards,

 

LC

Interested in learning Power BI and DAX? Check out my blog at www.finance-bi.com

 

 

If i un-pivot them together data is looking like this.But i dont want data like this, 

 Untitled.png

i want them in separate columns like this,

Untitled1.png

so that i can see values on my X-axis like Date BD1 ID1, Date BD2 ID2,  Date BD3 ID3, etc..,

All this i am doing to represent all my BD values in one line, and ID values in another line in the graph.

Thank you.

There you go @yodha :

yodha_01.JPG

yodha_03.JPG

With pleasure

PBIX ,

Hope it helps

 

Regards

Hi @YJ 

 

While Merging Inner join is creating duplicate rows in the data.

 

Thank you

 

 

Thank you so much, able to achive the requirement now, help appreciated. Smiley Happy

Thanks for the reply,

yes, i want to represent BD and ID with two separate lines in the chart that's why am un-pivoting them separately.

 

 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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