Forum Discussion
Condensing a column with values categorized by another column
Hi,
I have a table (not excel, but on SQL sever) that essentially looks like this
id | Name | Money | Type
0 Sean 10000 b
1 Sean 10000 c
2 Sean 10000 b
3 Sean 10000 c
4 John 10000 b
5 John 10000 b
6 John 10000 c
7 Sean 10000 b
8 John 10000 c
9 Sean 10000 c
'Money' is the amount of money in dollars, and 'Type' indicates the type of money (b is billing and c stands for cash-in)
Within Power BI, I want to restructure and condense this table so that it ultimately looks like this (Whether by creating a new query or creating a new table):
Name | Money | Type
Sean | 30000 | b
Sean | 30000 | c
James | 20000 | b
James | 20000 | c
What I want is that I want each person's sum of billing and cash-in. This is intended for me to later calculate 'Outstanding Cash-In', which is equivalent to Billing - Cash-in.
Can anyone help me with this? Or can you think of any other way than creating a new query and creating a new table? (maybe creating a new measure using DAX? I simply don't know just yet)
Thank you!
- Anonymous8 years ago
Hi
You can do this in Query Editor.
In Query Editor, Go to Transform Tab, Select Group By option.
The result will be :
Hope this helps.
Thanks
Raj
1 Reply
- AnonymousNot applicable
Hi
You can do this in Query Editor.
In Query Editor, Go to Transform Tab, Select Group By option.
The result will be :
Hope this helps.
Thanks
Raj