+ Reply to Thread
Results 1 to 25 of 25

count value by item and date match

  1. #1
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    count value by item and date match

    i am using a formula to count of value match item and date. kindly help me where i am missing this b/C formula is not giving result proper. kindly mention both Criteria Feb and Feb-15.
    Thanks.
    L2:
    =SUMIFS(B3:G7,A3:A7,I2,B1:G1,"="&EOMONTH(K1,0))
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,208

    Re: count value by item and date match

    Try this:

    =SUMPRODUCT(B3:G7,(A3:A7=I2)*(B1:G1=EOMONTH(K1,0)))
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    Hi AliGW,
    Thanks for your reply, its working perfect.
    But whereabouts only Feb.

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,208

    Re: count value by item and date match

    But whereabouts only Feb.
    What does that mean?

    And what on Earth does this mean?

    kindly mention both Criteria Feb and Feb-15.
    No clue what you are trying to achieve. Sorry!

  5. #5
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    your formula working on Feb-15, if i use only month Feb then how this formula work?

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,208

    Re: count value by item and date match

    Why do you need to do that? All data is February 2015 anyway. You need to be clear about your reasoning.

  7. #7
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    i have so many others year data in this file. i share just sample so that i need only Month.

  8. #8
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    Hi AliGW,
    i am using your formula but i increased column to find value, formula is not working. can you tell me where is missing?
    see the attached file.
    Attached Files Attached Files

  9. #9
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,819

    Re: count value by item and date match

    Paste the following in J4:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Drag the fill handle over to cell L4,
    While J4:L4 are still selected drag the fill handle down to L8.
    Let us know if you have any questions.
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

  10. #10
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    Hi JeteMc,
    perfect working, but tell me on thing i use only Month like Jan, Feb, Mar then this formula is not working, can you tell me how to handle this?

  11. #11
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,819

    Re: count value by item and date match

    If I understand the question correctly, typing in the month name, or abbreviation, doesn't work because EOMONTH needs a numerical value in the first argument.
    Perhaps this article will help: https://support.office.com/en-us/art...rs=en-US&ad=US
    If I have misunderstood the question, please update and re-upload the file to demonstrate where the formula is not working.
    Let us know if you have any questions.

  12. #12
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    please see the new file where i enter Jan, Feb and Mar then result are #value.
    Attached Files Attached Files

  13. #13
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,819

    Re: count value by item and date match

    "Jan", "Feb" and "Mar" are text strings not numeric values so the EOMONTH function returns the #VALUE error.
    Is there some reason that the formula from post #9 applied to the file attached to post #8 is problematic?
    Let us know if you have any questions.

  14. #14
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,819

    Re: count value by item and date match

    It occurs to me that you may be looking to sum sales from Jan, Feb or March of multiple years.
    To do that you could use the following (as modeled in the attached file):
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Note that the dates are still in J2:L2, however the custom formatting is changed to mmm.
    Let us know if you have any questions.
    Attached Files Attached Files

  15. #15
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    Hi JeteMc,
    thanks for guidance, really fantastic,
    thanks a lot,
    can you help me more in it, selected date data can be find out by this formula?
    please see the file start date and end date. if change end date formula return on end data
    Attached Files Attached Files

  16. #16
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,819

    Re: count value by item and date match

    Try the following:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Let us know if you have any questions.

  17. #17
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    Hi JeteMC,
    its super really, kindly tell me i am comparing Jan 2015 and Jan 2016 both up to June-15 and June-2016, i am using this to find Jan 2016
    figure but failed. can you tell me where i am missing?

    =IF(AND(O$11>=$R$10,O$11<=EOMONTH($U$10,0)),SUMPRODUCT($B$4:$M$8,($A$4:$A$8=$N12)*($B$2:$M$2=EOMONTH(O$11,0))*(year(b2:m2=year(p11)),"")

    currently formula is working perfect, i want to choose as start date and end date Jan 15 to Apr - 2016.
    see the file.

    thanks
    Attached Files Attached Files

  18. #18
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,208

    Re: count value by item and date match

    Change the date in U10 from 01/04/2015 to 01/04/2016:

    Excel 2016 (Windows) 32 bit
    N
    O
    P
    Q
    R
    S
    T
    U
    V
    W
    X
    Y
    Z
    10
    Start Date
    January
    End Date
    April
    11
    Jan-2015
    Jan-2016
    Feb-2015
    Feb-2016
    Mar-2015
    Mar-2016
    Apr-2015
    Apr-2016
    May-2015
    May-2016
    Jun-2015
    Jun-2016
    12
    supriment powder 18000 2000 5500 0 8900 9000 6000 7500 900 9000
    13
    integrity shower 5000 7500 7500 0 5500 6000 7000 6500 6000 8000
    14
    manpolat plate 7000 6500 2000 0 7500 8000 5000 4000 700 7000
    15
    single chamber 1000 2500 1500 0 8000 9000 11000 15000 750 5000
    16
    dual chamber 9000 11000 2000 0 9000 10000 12400 20000 1100 7000
    Sheet: Sheet1

  19. #19
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,208

    Re: count value by item and date match

    If you want to hide columns after April 2016, change the formula in O12 to this:

    =IF(P$11>$U$10,"",IF(AND(O$11>=$R$10,O$11<=EOMONTH($U$10,0)),SUMPRODUCT($B$4:$M$8,($A$4:$A$8=$N12)*($B$2:$M$2=EOMONTH(O$11,0))),""))

    Excel 2016 (Windows) 32 bit
    N
    O
    P
    Q
    R
    S
    T
    U
    V
    W
    X
    Y
    Z
    10
    Start Date
    January
    End Date
    April
    11
    Jan-2015
    Jan-2016
    Feb-2015
    Feb-2016
    Mar-2015
    Mar-2016
    Apr-2015
    Apr-2016
    May-2015
    May-2016
    Jun-2015
    Jun-2016
    12
    supriment powder 18000 2000 5500 0 8900 9000 6000 7500
    13
    integrity shower 5000 7500 7500 0 5500 6000 7000 6500
    14
    manpolat plate 7000 6500 2000 0 7500 8000 5000 4000
    15
    single chamber 1000 2500 1500 0 8000 9000 11000 15000
    16
    dual chamber 9000 11000 2000 0 9000 10000 12400 20000
    Sheet: Sheet1

  20. #20
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    Hi Ali GW,
    see the snap Feb-2016 fugue are ZERO and show June-2015 data.it will show data upto Jan-15 to Apr-2016
    Attached Images Attached Images

  21. #21
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,208

    Re: count value by item and date match

    Look at post #19.

    In future, instead of drip-feeding us the real data, present us with it all at the outset. If we had had the file in post #17 right at the start, this would have been solved by now.

    The value in E2 is incorrect. It says this: 28/02/2016

    2016 was a leap year, so change it to this: 29/02/2016

    Excel 2016 (Windows) 32 bit
    E
    2
    29/02/2016
    3
    4
    6000
    5
    7000
    6
    3100
    7
    2000
    8
    1800
    Sheet: Sheet1

    Excel 2016 (Windows) 32 bit
    N
    O
    P
    Q
    R
    S
    T
    U
    V
    W
    X
    Y
    Z
    10
    Start Date
    January
    End Date
    April
    11
    Jan-2015
    Jan-2016
    Feb-2015
    Feb-2016
    Mar-2015
    Mar-2016
    Apr-2015
    Apr-2016
    May-2015
    May-2016
    Jun-2015
    Jun-2016
    12
    supriment powder 18000 2000 5500 6000 8900 9000 6000 7500
    13
    integrity shower 5000 7500 7500 7000 5500 6000 7000 6500
    14
    manpolat plate 7000 6500 2000 3100 7500 8000 5000 4000
    15
    single chamber 1000 2500 1500 2000 8000 9000 11000 15000
    16
    dual chamber 9000 11000 2000 1800 9000 10000 12400 20000
    Sheet: Sheet1
    Last edited by AliGW; 03-09-2019 at 02:35 AM. Reason: Typo corrected.

  22. #22
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    its also near to solve this, but your formula is working perfect but i dont know why Feb-16 data is still ZERO showing? can you tell me?
    Thanks

  23. #23
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,208

    Re: count value by item and date match

    Look at post #21.

  24. #24
    Forum Contributor
    Join Date
    12-08-2018
    Location
    pakistan
    MS-Off Ver
    2013-365
    Posts
    500

    Re: count value by item and date match

    Thank for the guidance,
    Special thanks to JeteMC, really fantastic working Boss,
    AliGW you also help me to solve this. thanks a lot both of you.
    thanks again.

  25. #25
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,819

    Re: count value by item and date match

    You're Welcome. Thank You for the feedback and for marking the thread as 'Solved'. I hope that you have a blessed day.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] month wise count item and price fluctuation between buying date
    By majidsiddique in forum Excel General
    Replies: 23
    Last Post: 02-19-2019, 01:35 AM
  2. Match Item with Invoice and Replace any missing Item AUTO
    By majidsiddique in forum Excel General
    Replies: 17
    Last Post: 01-15-2019, 03:43 AM
  3. Replies: 4
    Last Post: 07-18-2018, 12:30 PM
  4. [SOLVED] Find item(s) in a cell and match to item(s) in a list
    By seleseped in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 04-11-2017, 12:06 PM
  5. [SOLVED] Vba to match item description and copy/paste item code to other sheet
    By Sintek in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-31-2017, 11:29 AM
  6. [SOLVED] 2 Column Look Up / Match - Return Item on or to the nearest date
    By DHHM in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-02-2016, 06:55 AM
  7. Find last date an item was entered and count the days since
    By hlb129 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-14-2014, 08:14 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1