web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / SUMIFS AND MONTH FUNCTION
Power Apps
Unanswered

SUMIFS AND MONTH FUNCTION

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hey guys, been having a hard time finding answers.

I have a datatable on my powerapps and i just want the sum of the amount based on 2 columns - ID code and Month which should be the same as the current month.

  1. i dont know how to write or code the sumifs
  2. and use Month on the column (date) to match the current date

 

This is the formula i made:

 

If(IsBlank(TextInput3_Searchbox)," ",1000-Sum(Filter('Employee Discount | Discount Data', TextInput3_Searchbox.Text= 'Employee Code'&& Month('Transaction Date') = Month(Today()),Discount)

 

HELP!!!!!!!!!!

Categories:
I have the same question (0)
  • PriyankaGeethik Profile Picture
    3,320 Super User 2024 Season 1 on at

    Hi @Anonymous ,

     

    Assuming your logic is fine. Does below code works in your case ?

     

    If(IsBlank(TextInput3_Searchbox)
    ," ",
    1000-Sum(Filter('Employee Discount | Discount Data', TextInput3_Searchbox.Text= 'Employee Code'&& Month('Transaction Date') = Month(Today()),Discount)))

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Sadly does not 😞

  • PriyankaGeethik Profile Picture
    3,320 Super User 2024 Season 1 on at

    Hi @Anonymous ,

     

    What is the error message you getting ?

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi, it just says error in formula, please try revising...

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @Anonymous ,

    Your two possible outcomes are different types (Text and Numeric) and you also had a bracket in the wrong place - try this

    If(
     IsBlank(TextInput3_Searchbox),
     0,
     1000-
     Sum(
     Filter(
     'Employee Discount | Discount Data', 
     'Employee Code' = TextInput3_Searchbox.Text && 
     Month('Transaction Date') = Month(Today())
     ),
     Discount
     )
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi, i used it and there isn't any error showing.. but it doesn't recognize the Transaction date (shown on the table as "Saturday, August 21, 2021" as August I guess? because it still showing "1000"

    IRNPH_0-1630374254481.png

     

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    @Anonymous ,

    What type of field is 'Transaction Date' and what is your Data Source?

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @WarrenBelz its sharepoint and its a date

     

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @Anonymous ,

    There is something else wrong here - if 'Transaction Date' is a date field in SharePoint, then 

     Month('Transaction Date') = Month(Today())

    will show all the records with the current month with one proviso - Month() is not Delegable, so you will not get all the records on large data sets - how big is you list?

    Also what code are you using to display the date the way you have it in the screenshot?

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @Anonymous ,

    Just checking if you got the result you were looking for on this thread. Happy to help further if not.

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 610

#2
Haque Profile Picture

Haque 317

#3
WarrenBelz Profile Picture

WarrenBelz 315 Most Valuable Professional

Last 30 days Overall leaderboard