Power query assistance

Copper Contributor
Hi guys,
New to the community! And very new to power query I have a task where I have to import data containing a company’s bank statements and be able to categorise it’s cash inflows and outflows based on if text contains a certain criteria.. Unfortunately there are probably 70 categories or so.. I am having some success with the conditional column at the moment but I feel that the conditional column is limited as I can’t find a way to incorporate Nested if ( and statements to categorise my cash flows..

A specific example of a problem I have :
If a bank statement contains the word “charges” - then categorise as charges

If a bank statement contains the word “purchase ledger” - then categorise as purchase ledger..

A problem I face is when the conditional column has limits when the bank statement contains both “charges” and “purchase ledger” in its name.

Another problem I have is when I input the following query:

If text contains “adv”, output : interest payments..
This is a real issue as it miscategorises bank statements with advance in its description as interest payments also :\

Do any of you guys know an easy way to sort out my problems using power query ie:
(multiple categories and at times multiple criteria needed to categorise cash flows)

If anyone wants any further info and files for more clarification would be happy to provide it.

Hope you guys can help! Many thanks for your assistance
1 Reply

@Michaellaudrup9 

It looks like that not an issue with Power Query. Formal logic is not defined correctly. For the first

 

if condition1 then option1

else

    if condition2 then option2

    else NOTHING IS DEFINED FOR THAT

 

Power query is only maps your logic, it doesn't create its own.