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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
UB400
Regular Visitor

Splitting Column containing Debits and Credits

Hi all, I'm new to PowerBi and am currently working through the tutorials.

I have a Table that has a Debit/Credit Column with a Text value of C or D and another column which contains the related amount.

 

I would like to split these into two Columns, with Headers of "Debit" and "Credit" with the content of the Columns being the amount.

 

Currently

 

Date:  Description: Debit/Credit: Amount:
01/18 Invoice 001  Debit                 100

 

I want to change it to 

 

Date:  Description: Debit:  Credit:

01/18  Invoice         100

 

Any help would be greatly appreciated.

1 ACCEPTED SOLUTION
shebr
Resolver III
Resolver III

Hi @UB400

 

In your query designer, (see image below) do the following:

 

1. Highlight your Credit/Debit column

2. Click on 'Pivot' in the ribbon above

3. Select 'Amount' in the values options

4. Click OK.

 

You should have the data in your required format. (See image 2) 

 

Let me know how you get on.

 

Thanks

 

shebr

 

pivot.JPGPivot 2.JPG

View solution in original post

3 REPLIES 3
shebr
Resolver III
Resolver III

Hi @UB400

 

In your query designer, (see image below) do the following:

 

1. Highlight your Credit/Debit column

2. Click on 'Pivot' in the ribbon above

3. Select 'Amount' in the values options

4. Click OK.

 

You should have the data in your required format. (See image 2) 

 

Let me know how you get on.

 

Thanks

 

shebr

 

pivot.JPGPivot 2.JPG

UB400
Regular Visitor

@shebr and @Greg_Deckler thank you both for responding, greatly appreciated. I'm just gobsmacked at how things are done in PowerBI. @shebr I would never have figured that one out, that is amazing, thank you. I have a lot of learning to do, and with the support that I'm receiving here, I'm looking forward to the journey

Greg_Deckler
Community Champion
Community Champion

I would do this in the Query Editor and add two Conditional Columns. Basically for Debit column, if the Debit/Credit column is "Debit", then Amount, otherwise null.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors