+ Reply to Thread
Results 1 to 8 of 8

List Results Based on Multiple Criteria

  1. #1
    Registered User
    Join Date
    01-17-2013
    Location
    Beaumont, CA
    MS-Off Ver
    Excel 2010
    Posts
    5

    List Results Based on Multiple Criteria

    Hello all. I'm new to this forum. I am trying to list position numbers that meet multiple criteria. I am currently using Sumproduct to count them but I also need to list the results. the sumproduct formula is =SUMPRODUCT((A:A>1)*(C:C=52280)*(W:W=1)) Where A:A is the Position Count (where the number of employees in the same position number is more than 1), C:C is the Department Number and W:W is maximum head count for a position number. I'm trying to list the position numbers (B:B) that meet those criteria.

    Thank you in advance!

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,933

    Re: List Results Based on Multiple Criteria

    Hi scott and welcome to the forum

    perhaps it would be easier to help you if you uploaded a sample workbook, showing what data you are working with, a few examples of what your expected outcome would be, and how you would arrive at that (remove any confidential info if necessary).
    To attach a file to your post,
    click advanced (next to quick post),
    scroll down until you see "manage file",
    click that and select "add files" (top right corner).
    click "select files" find your file, click "open" click "upload" click 'done" bottom right. click "submit reply"

    Once the upload is completed the file name will appear below the input boxes in this window.
    You can then close the window to return to the new post screen.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    01-17-2013
    Location
    Beaumont, CA
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: List Results Based on Multiple Criteria

    Thank you FDibbins. Attached is a file. I removed most of the other data so the column letters are different than the original post.

    Thank you again!
    Attached Files Attached Files

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,933

    Re: List Results Based on Multiple Criteria

    thanks for the file

    This may be too simplistic, but have you considered using filters? you already have them applied, just un-select what you dont want to see, column-by-column, and you will end up with the list you want?

  5. #5
    Registered User
    Join Date
    01-17-2013
    Location
    Beaumont, CA
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: List Results Based on Multiple Criteria

    Haha! Good call. I am using the filters to check the results of the formulas. I will be sending this report to about 15 different Department heads (each with a different Department Number) so I will need different results for different Department Numbers. This sample is just one of four different sets of criteria I am looking for from the same dataset so I'm hoping to have some automation in report. Once I get the formula to work I can change the variables to meet each department's criteria. I hope that makes sense...

  6. #6
    Registered User
    Join Date
    01-17-2013
    Location
    Beaumont, CA
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: List Results Based on Multiple Criteria

    Here is another version of my spreadsheet with a more complete version of the data. The StaffingData Tab is my main data (this is downloaded from a query from our Payroll database). The ITSD and Admin tabs are samples of 2 of the 15 departments I will send reports to. I am trying to keep the reports simple for the department heads to review. But the goal is to run the payroll query at the beginning of each month and have these cells updated automatically.

    Thank you again for your help...
    Attached Files Attached Files

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,933

    Re: List Results Based on Multiple Criteria

    It would make it easier to understand if the headings in sheet2 bore any relation to those in sheet1

    and on a side note, all of your sumproduct functions can be done with a much simpler countifS() function...
    =+SUMPRODUCT((StaffingData!C:C="52280")*(StaffingData!F:F<>"V"))
    =COUNTIFS(StaffingData!C:C,$A$2,StaffingData!F:F,"<>V")

    =+SUMPRODUCT((StaffingData!C:C="52280")*(StaffingData!F:F<>"V")*(StaffingData!A:A>1))
    =COUNTIFS(StaffingData!C:C,"52280",StaffingData!F:F,"<>V",StaffingData!A:A,">"&1)

  8. #8
    Registered User
    Join Date
    01-17-2013
    Location
    Beaumont, CA
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: List Results Based on Multiple Criteria

    Thank you so much. I appreciate the help. Is there a way to list the position numbers that meet those criteria?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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