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

A new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.

Reply
CarlsBerg999
Helper V
Helper V

IF statement not working

Hi,

 

Im trying to write a simple if stamenet but it doesn't work with numbers or measures.

IF(SUM('table1'[Column1]) = 50000,1,2) --> Doesnt work. Says "Too few arguments were passed to the IF function. The minimum argument count for the function is two. 
 
IF(SUM('table1'[Column1]) = "50000",1,2) ---> Works.  
 
What is wrong with the first version?
1 ACCEPTED SOLUTION

Actually this got fixed with putting an additional space. For example 50000 , ValueIfTrue

Before i had 50000,ValueIfTrue

View solution in original post

3 REPLIES 3
PhilipTreacy
Super User
Super User

Hi @CarlsBerg999 

That doesn't make much sense.  Unless you use comma as decimal separator?

Regards

Phil



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


PhilipTreacy
Super User
Super User

Hi @CarlsBerg999 

There's nothing syntcatically wrong with your first version

 

IF(SUM('table1'[Column1]) = 50000,1,2)

 

So it must be something else.  Is this the entirety of the code?

What is your decimal separator?  Comma or period?  

regards

Phil



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


Actually this got fixed with putting an additional space. For example 50000 , ValueIfTrue

Before i had 50000,ValueIfTrue

Helpful resources

Announcements
May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.