How to add multiple if coditions in Custom column

Rafaqat Ali 1 Reputation point
2021-05-31T16:52:20.243+00:00

I am trying to add custom column with multiple conditions with if statement but getting the following error in the Image.

Need help if anyone can, help would be highly appreciated.

101176-image.png

Microsoft 365 and Office Excel For business Windows
Community Center Not monitored
{count} votes

2 answers

Sort by: Most helpful
  1. Lz._ 9,016 Reputation points
    2021-05-31T21:06:36.533+00:00

    @Rafaqat Ali

    2 things obvious in your picture:

    • The 2nd if is written If. Change it with if (Power Query M is case sensitive)
    • After the above if a space is missing before [Service Type]

    If you make those changes and pay attention not to make the same mistakes again :) you're on the right way...

    4 people found this answer helpful.

  2. Emily Hua-MSFT 27,796 Reputation points
    2021-06-01T08:00:30.553+00:00

    @Rafaqat Ali

    Please refer to Lz-3068's reply.

    Besides, here is an article "The IF Function in Power Query: Tutorial, Example If Statements and Errors Explained (Complete Guide)", you may have a look.

    Please note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link.


    If an Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.