+ Reply to Thread
Results 1 to 17 of 17

Count if with conditions...

Hybrid View

Winterfell Count if with conditions... 01-31-2016, 04:59 PM
Richard Buttrey Re: Count if with... 01-31-2016, 05:07 PM
Winterfell Re: Count if with... 01-31-2016, 05:57 PM
Winterfell Re: Count if with... 02-01-2016, 03:40 PM
Richard Buttrey Re: Count if with... 02-01-2016, 03:55 PM
Winterfell Re: Count if with... 02-01-2016, 04:08 PM
Richard Buttrey Re: Count if with... 02-01-2016, 04:30 PM
Winterfell Re: Count if with... 02-01-2016, 04:47 PM
Richard Buttrey Re: Count if with... 02-01-2016, 04:49 PM
Winterfell Re: Count if with... 02-01-2016, 04:59 PM
Richard Buttrey Re: Count if with... 02-01-2016, 07:08 PM
Winterfell Re: Count if with... 02-02-2016, 03:22 PM
Richard Buttrey Re: Count if with... 02-02-2016, 07:45 PM
Winterfell Re: Count if with... 02-03-2016, 01:36 AM
Richard Buttrey Re: Count if with... 02-04-2016, 07:21 AM
Winterfell Re: Count if with... 02-04-2016, 05:44 PM
Winterfell Re: Count if with... 02-05-2016, 04:27 PM
  1. #1
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Count if with conditions...

    Hi People,

    I am looking for a way to resolve this issue. But i would have to explain a little...

    Every equipment should be tested one year after set up. Then this test should be repeated every 2 years after the first test for the life of the equipment. The equipment life is 15 years. lets call this the certification test
    However, in addition, there is an overhaul done every 5 years. this overhaul test can also coincide with the certification test. These are separate tests.

    The test starts on the date of the title transfer. so all equipment within a given year, should be ready for the first test by the end of the first year.

    For example, lets assume title transfer occurred Jan 2007. by Jan 2008 the first certification test check is due. By Jan 2010, the next certification test is due. By Jan 2012, the overhaul and certification test are due.

    However, for equipment with title transfer in 2009, these set will also be included with the original Jan 2007 set in jan 2010. etc

    The same rule applies to all equipment with title transfer in 2008, 2010, etc.

    The question now is : Is there a way to capture these tests per year on a column starting from AS in my attachment?

    I appreciate your help!
    Attached Files Attached Files
    Last edited by Winterfell; 02-01-2016 at 04:08 PM.

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Count if with conditions...

    Almost certainly there will be a way and I was with you until you mentioned what seems to be special rules for transfers in 2003 and mention of 2000 & 2005. It doesn't help that the earliest date is in any case 2007.

    As always with these things it's much better if you manually add the results you expect so that we can understand the end goal. If you add these results and then upload the workbook again, explaining this '2003' situation a little more then no doubt we can help further. Be sure to include all year that are relevant - which implies 2003 and later.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Hi Richard,

    Thanks. I have edited the post. Please only consider dates from 2007.

    The sums are also now in the attachment.

    Rgds,
    Winterfell

  4. #4
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Just bumping the post...

    Looking forward to your replies...

  5. #5
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Count if with conditions...

    Hi,

    Would you also explain how you have calculated the numbers in the table with some narrative that refers to the original data. e.g. Certification total 654 for 2010 counts Cells En:En, En:En..etc where E cell is......whatever the rule may be

  6. #6
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Hi Richard,

    Thanks just did in the attachment...

  7. #7
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Count if with conditions...

    Hi,

    When I filter column E and count the filtered rows :-

    For AX8 - 2007 & 2009 I count 652 not 654
    For AX9 - 2008 & 2010 I count 741 not 743
    For AX10 - 2007 & 2009 & 2011 I count 1082 not 1332
    For AX11 - 2008 & 2010 & 2012 I count 1145 not 1148

    Can you explain these discrepancies since clearly I'm not understanding your rules.

  8. #8
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Hi Richard,

    You are correct. My mistake.
    AX10 was a formula error. 2007 equip was counted twice.

  9. #9
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Count if with conditions...

    ...But what about the much bigger difference with AX10?

  10. #10
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Hi Richard,

    AX10 should be AW5 (2007) +AW7 (2009) +AW9 (2011) =1082. The issue is that 2007 was counted twice which should not have been.

    So your initial count was correct. AX10 is 1082 and not 1332.

  11. #11
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Count if with conditions...

    Hi,

    Does the attached offer you a way forward.

    There may be a more complex array formula somewhere hereabouts but perhaps this pragmatic approach which uses helper columns is suitable.
    Attached Files Attached Files

  12. #12
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Richard!

    Fantastic. Thank you! Now just a few more questions.

    How do I expand the formula to show the serial numbers as well under every given year from 2007 using these conditions?


    I can put the years in a column and then display the serial numbers under that column?

  13. #13
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Count if with conditions...

    Hi,

    That's a totally different requirement to the earlier Q. There you were counting things. i.e. you were getting a single number for the year in question. What you're now asking for is to list many 'things' for the year in question. Which doesn't involve a formula and of course is arguably much easier if you use a Pivot Table. I have assumed you want to see a list of unique serial numbers in each year rather than a list of unique numbers across all years.

    The Pivot Table uses columns A,B&D from the A:E range on Sheet1
    Attached Files Attached Files

  14. #14
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Hi Richard,

    I think we are getting very close Yes, this is complicated but thanks a lot for coming with me this far.

    I wanted to sort them according to the conditions before counting using the pivot. Counting directly using the pivot may not be sufficient as there may be overlaps.

    Yes I want to see a list of unique serial numbers per year only if they meet the criteria for testing only one year after the title transfer and every subsequent 2 years just like in our table.


  15. #15
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Count if with conditions...

    Hi,

    Been struggling a bit with this, not least because during the development & checking the array formulas take 30 seconds or so each time the filter is changed.

    Anyway here's the latest. I've added two Pivot Tables each selecting a different alternate series of years. You could of course just use one and change the years each time.
    Attached Files Attached Files

  16. #16
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Hi Richard,
    Whoa! Thanks a lot.
    I just realised there are a few conditions to be met before the test can be scheduled.
    1. The material type, L1, must either be a standard or an elite model.
    2. If the service term (I1) is a TYP A, then the service finish date (K1) must be in the future
    3. If the service term (I1) is a TYP B, then the surety end date (H1) must be in the future.
    How can these conditions be incorporated before counting using the earlier test conditions?
    I have included some fields till row 546 in the attached data
    Is there a reason why we have 0.5, pls refer to X151:X166?
    Thanks a lot for your help Richard.. and I look forward to hearing from you soonest
    And yes please explain how you used the array formulas
    Attached Files Attached Files

  17. #17
    Registered User
    Join Date
    07-18-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    35

    Re: Count if with conditions...

    Hi Richard,

    Found the way around this issue with a colleague.

    But thanks a lot for your assistance

    Much appreciated

+ 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] Count and many conditions
    By Newbuilder in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 02-02-2016, 03:57 PM
  2. How to count with some conditions
    By qwerty22 in forum Excel General
    Replies: 6
    Last Post: 10-22-2014, 01:09 PM
  3. How to Count with 2 conditions?
    By Lewis Koh in forum Excel General
    Replies: 6
    Last Post: 04-21-2010, 11:48 AM
  4. Count with two conditions
    By smilegirl in forum Excel General
    Replies: 1
    Last Post: 12-04-2009, 01:19 PM
  5. Count with 2 conditions
    By lalicom in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-16-2009, 03:38 PM
  6. Count with 2 conditions, second one OR
    By j.figueras@verizon.net in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-04-2006, 01:00 PM
  7. [SOLVED] How to count after 2 conditions are met
    By Dave Schwinger in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-03-2006, 04:35 PM

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