Formula Help - Multiple criteria

I'm fairly new to Numbers and am struggling to work out the formula to manage multiple sumif functions. I want to be able to calculate the total of column 'C' where A & B are identical. For example sum of column C where  A=James, B=Vehicle. Sorry if I'm not being clear. Basically total of $ in 'C' where A = James and B = Vehicle.
Thankyou in advance for the help. 
A
B
C
James
Vehicle
$100.00
Tom
Office
$200.00
James
Office
$150.00
Brad
Vehicle
$275.00

Dynamic using cell references. I missed the & to make it work.
=SUMIFS(Table 1::C,Table 1::A,"="&A2,Table 1::B,"="&B2)
If lucky James has two vehicles,
And you can add more combinations to Table 1-1
Regards,
Ian.

Similar Messages

  • Help me write command in vba(excel) to search and find special cells based on multiple criteria

    Hi 
    My name is Majid Javnmard , I am using Microsoft Office Excel 2010 and I encountered a problem. I sent you a simple example of my excel file that i want to write a command in vba to search and find special cell and copy the row which special cell is in there
    somewhere , but the problem is how can i find my special cell with multiple criteria or how can i find my all special cells and copy them somewhere !!? 
    Let me explain on file that i sent :
    This file has 4 headers (X,Y,PerturbNumber,Value), the problem is for example : I want write commnd in vba to copy all rows that each of them has (X=12 and Y=13). how can i ? can you help me ?
    My
    file : http://s000.tinyupload.com/index.php?file_id=69742844961096241754
    Many Thanks
    Majid 

    This worked for me, based on your example:
    Sub pMain()
    Dim wsSource As Excel.Worksheet
    Dim wsDest As Excel.Worksheet
    Dim lSource As Long
    Dim lDest As Long
    Dim lLast As Long
    With ThisWorkbook
    'Change to suit
    Set wsSource = .Worksheets("Sheet1")
    Set wsDest = .Worksheets.Add
    End With
    wsSource.Rows(1).Copy
    wsDest.Range("A1").PasteSpecial xlPasteValues
    lDest = 2
    lLast = wsSource.Cells(wsSource.Rows.Count, "A").End(xlUp).Row
    For lSource = 1 To lLast
    'Put the conditions below:
    If wsSource.Cells(lSource, "A") <> 12 Then GoTo linNext
    If wsSource.Cells(lSource, "B") <> 30 Then GoTo linNext
    'If wsSource.Cells(lSource, "C") <> "value" Then GoTo linNext
    'If wsSource.Cells(lSource, "D") <> "value" Then GoTo linNext
    'Conditions were met:
    wsSource.Rows(lSource).Copy
    wsDest.Rows(lDest).PasteSpecial xlPasteValues
    lDest = lDest + 1
    linNext:
    Next lSource
    End Sub
    Felipe Costa Gualberto - http://www.ambienteoffice.com.br

  • Grouping of multiple criterias as expression

    Dear all
    I want to do a grouping of multiple criterias as expression .
    Single grouping is possible , but when group within a group comes things doesnt work for me.
    User would define the comibination
    For example i have 4 criterias
    C1
    C2
    C3
    C4
    Basic grouping works for example :
    (C1&C2) | (C3&C4)
    Complicated grouping i have no idea how to implement it.
    (((C1&C2) | (C3&C4))&(C1&C2) )
    I need validate if the expression is correct and need to pick up all the groups and do the AND or OR.
    Any help woul dbe appriciated
    Regards
    pacs

    fiveohg wrote:
    Complicated grouping i have no idea how to implement it.
    (((C1&C2) | (C3&C4))&(C1&C2) )
    I need validate if the expression is correct and need to pick up all the groups and do the AND or OR.As already suggested: you could write your own grammar and let a parser-generator create a lexer/parser for you.
    Another option is to use some scripting engine and bind your C-variables before evaluating your expression:
    import javax.script.*;
    public class Foo {
      public static void main(String[] args) throws Exception {
          String expression = "(((C1 && C2) || (C3 && C4)) && (C1 && C2))";
          ScriptEngineManager manager = new ScriptEngineManager();
          ScriptEngine engine = manager.getEngineByName("js");
          engine.put("C1", true);
          engine.put("C2", true);
          engine.put("C3", false);
          engine.put("C4", true);
          System.out.println(engine.eval(expression));
    }Note that you cannot user '|' and '&', in that case.
    The JavaScript (Rhino) engine is built-in in Java 6, but there are more that can be imported: [https://scripting.dev.java.net/]

  • Counting rows with multiple criteria

    I know this is a silly beginner question, but is there an easy way to count the number of rows in a table which match criteria based on different columns (sort of a countif with multiple criteria). For example, if Column A in a table has "All, Some, None" responses and Column B has "Main, Off" responses, is there an easy way to count the number of rows in which Column A has All and Column B has Off?

    Neondiet wrote:
    From an intellectual and philosophical view I agree with you. But from a practical view what I really want to do is just use one application for my spreadsheet tasks, not jump back and forth because one sheet I share with MS Windows users, and another with Numbers users, and another with OS X users who don't have Numbers or Excel but do have NeoOffice. Maybe I have to settle for that though.
    Yeah... this kind of situation stinks. Its like needing to writing software that will run on both Macs and PCs.
    Anyway, I've followed the advise in this forum and resorted to using a hidden column with concatenated values to solve my own problem, though it does seem like a bit of a hack compared to managing a single formula in a single cell. Horses for courses I suppose.
    jaxjason has posted a very elegant pivot table like solution that utilizes this technique. See http://www.numberstemplates.com/forums/showthread.php?t=36
    Btw, from what I've read on the net to date, SUM (in Excel) with an array formula answers the original authors problem of counting occurrences of values, not SUMPRODUCT; which I believe sums up the contents of cells in a range, if cells in other ranges match specific criteria.
    Yes, if you use the '*' (as indicated above) then SUM() is sufficient though SUMPRODUCT() will work as it degenerates to SUM when there is only one argument. If you use two arrays as arguments (like: = SUMPRODUCT((A1:A4="All"), (B1:B4="Off")), then SUMPRODUCT() is necessary. Here's my understanding of how it works (I hope your able to follow my abuse of algebraic techniques):
    =SUM((A1:A4="All") * (B1:B4="Off"))
    expanding the array expressions...
    =SUM((A1="All", A2="All", A3="All", A4="All") * (B1="Off", B2="Off", B3="Off", B4="Off"))
    at this point Excel computes the equality expressions, for example...
    =SUM((TRUE, FALSE, TRUE, FALSE) * (TRUE, TRUE, FALSE, FALSE))
    expanding the array multiplication...
    =SUM((TRUE * TRUE, FALSE * TRUE, TRUE * FALSE, FALSE * FALSE))
    Excel, apparently, then, when forced to multiply Boolean values, maps TRUE -> 1 and FALSE -> 0...
    =SUM((1 * 1, 0 * 1, 1 * 0, 0 * 0))
    performing the multiplications...
    =SUM((1, 0, 0, 0))
    summing...
    =1 + 0 + 0 + 0
    resulting...
    =1
    I'm afraid, now, if I continue any further, Yvan will chastise me.

  • Formula Help - Running Total vs ???

    Post Author: schilders
    CA Forum: Formula
    Good Morning All,
    I'm creating a report that contains a field called CDM Item.  This field indicates whether a particular order set was used for a given record.  Valid entries for this field are numeric 6 through 9.  I would like to create a formula that tells me the number of records that have a cdm item = 6, another formula that tells me the number of records that have a cdm item = 7 etc.  I need to summarize these formulas into pre-defined groups. 
    I was thinking a running total or a manual running total would be useful here.  However, I wanted to get some input from other formula gurus here.  Thanks, in advance, for your help.

    Post Author: yangster
    CA Forum: Formula
    You don't need to create a manual running total for what you are after.simply create 4 running totals ( 1 for each item number) using a running total with the evaluate formula of cdm =  6 (changed for each number)and resetting after whatever grouping you needthe other alternative you could implement if you have mutliple grouping and wanted subtotals on differing levels is to create a formula for each case such as@case_cdm6if cdm = 6 then 1 else 0then insert sum for each formula on all the differing group levels that way you only have to worry about maintaining one formula if the criteria changes

  • Multiple criteria search with 4 dropdown lists

    I want to perform a multiple criteria search on a MySQL
    database. Users should be able to use from 4 dropdown lists in a
    form only one criterium, all 4 of them or 2 or 3.
    Each used dropdown list gives a numeric variable: Fvar1 ...
    Fvar4. The variables from the dropdown lists used should be matched
    with numeric fields in the database: DBvar1...DBvar4
    The numeric variables from the dropdown lists that are not
    used, should be ignored.
    Example: a user selects a value in dropdown list 2 and 3 and
    does not use dropdown lists 1 and 4. Fvar1 and Fvar 4 should then
    be ignored for the search, that has to be performed with Fvar2 and
    Fvar3, who have to be matched with DBvar2 and DBvar3.
    Anyone who can help me out with the WHERE statement in my SQL
    query?
    Your help will be greatly appreciated.
    Erik

    Erik61 wrote:
    > I want to perform a multiple criteria search on a MySQL
    database. Users should
    > be able to use from 4 dropdown lists in a form only one
    criterium, all 4 of
    > them or 2 or 3.
    Start by using the Advanced Recordset dialog box to create a
    query that
    looks for all four variables. Then switch to Code view and
    start carving
    up the code created by Dreamweaver.
    The query will look something like this:
    $query_getProducts = sprintf("SELECT product_name, price
    FROM products
    WHERE prod_type = %s AND colour = %s AND size = %s AND range
    = %s
    ORDER BY price ASC",
    GetSQLValueString($var1_getProducts, "text"),
    GetSQLValueString($var2_getProducts, "text"),
    GetSQLValueString($var3_getProducts, "text"),
    GetSQLValueString($var4_getProducts, "text"));
    Change it like this:
    $query_getProducts = "SELECT product_name, price
    FROM products
    WHERE ";
    $where = false;
    if (!empty($_GET['prod_type')) {
    $query_getProducts .= sprintf("prod_type = %s ",
    GetSQLValueString($var1_getProducts, "text"));
    $where = true;
    if (!empty($_GET['colour'])) {
    if ($where) {
    $query_getProducts .= 'AND ';
    $query_getProducts .= sprintf('colour = %s ',
    GetSQLValueString($var2_getProducts, "text"));
    $where = true;
    if (!empty($_GET['size'])) {
    if ($where) {
    $query_getProducts .= 'AND ';
    $query_getProducts .= sprintf('size = %s ',
    GetSQLValueString($var3_getProducts, "text"));
    $where = true;
    if (!empty($_GET['range'])) {
    if ($where) {
    $query_getProducts .= 'AND ';
    $query_getProducts .= sprintf('range = %s',
    GetSQLValueString($var4_getProducts, "text"));
    That builds the query in stages using $where to decide
    whether to add
    "AND" in front of the second, third, and fourth variables.
    David Powers, Adobe Community Expert
    Author, "The Essential Guide to Dreamweaver CS3" (friends of
    ED)
    Author, "PHP Solutions" (friends of ED)
    http://foundationphp.com/

  • Multiple criteria for Smart Playlists

    When I want to make a Smart Playlist with multiple criteria, such as a SP for my Classical and Jazz songs only, I select genre, then type in Classical, following that I click the "+" button next to that and put Jazz as my Genre. I click save, then I get a dialogue box that tells me about non-matching items. Is a multi criteria SP even possible or am I just not doing it right?

    Logically, that makes sense, of course (it's not your "entire" lib, it's just everything except Harry)
    There might be another way, but here's how I would do what you want:
    I'd create a new folder and place two SPs in it, one for classical and one for Jazz. Then I'd create a third one that consists of "Playlist Classical" and "Playlist Jazz".
    It sounds sloppy, but you could use that single folder for any playlist you wanted to use in this way, keeping the combination SPs out in the straight listing.
    Hope that helps
    <hr width="250" align="left">
    HangTime [Will Compute for Food] B-)>
    ♪♫ The Bullets and Bones Band ♫♪
    Disclaimer<hr width="250" align="left">

  • Sorting a Vector by multiple criteria

    Hi,
    I am trying to sort a Vector by multiple criteria. For example, the Vector must first be sorted by category 1, then category 2, etc.
    This is my code so far:
    Vector<Item> temp = new Vector<Item>(items.size());
    Collections.sort(temp, new ByFilename());
    Collections.sort(temp, new BySong());
    Collections.sort(temp, new ByArtist());
         private static class Item
              String CD, track, song, artist, details, filename;
              int row;
              Item(String c, String t, String s, String a, String d, String f, int r)
                   CD = c;
                   track = t;
                   song = s;
                   artist = a;
                   details = d;
                   filename = f;
                   row = r;
         private static class ByFilename implements Comparator<Item>
              public int compare (Item one, Item two)
                   return  one.filename.compareTo(two.filename);
         private static class BySong implements Comparator<Item>
              public int compare (Item one, Item two)
                   return  one.song.compareTo(two.song);
         private static class ByArtist implements Comparator<Item>
              public int compare (Item one, Item two)
                   return  one.artist.compareTo(two.artist);
         }Except this sorts the Vector by Filename, then sorts again from scratch by song, then again from scratch by artist. However, I want it sorted by Filename, with the duplicate Filenames sorted by song, and entries with the same Filename and songs, sorted by artist. I hope this makes sense!!
    Does anyone have any ideas? I tried sorting by filename, finding the duplicates, sorting these in a separate vector and then adding back in, but it didn't work and was too messy. There has to be an easier way... that is much less fiddly.
    Thanks in advance for any help :)

    Here's a demo of using chained comparators.
    import java.util.*;
    public class Item {
        String a, b, c;
        public Item(String a, String b, String c) {
            this.a = a;
            this.b = b;
            this.c = c;
        public String toString() {
            return  a +  b + c;
        public static void main(String[] args) {
            Item[] items = {
                new Item("0","1","1"),
                new Item("1","1","1"),
                new Item("0","1","0"),
                new Item("1","1","0"),
                new Item("0","0","1"),
                new Item("1","0","1"),
                new Item("0","0","0"),
                new Item("1","0","0"),
            Arrays.sort(items, new ByA(new ByB(new ByC(null))));
            System.out.println(Arrays.toString(items));
    class ByA implements Comparator<Item> {
        Comparator<Item> tieBreaker;
        ByA(Comparator<Item> tieBreaker) {
            this.tieBreaker = tieBreaker;
        public int compare (Item one, Item two){
            int result = one.a.compareTo(two.a);
            if (result == 0 && tieBreaker != null) {
                result = tieBreaker.compare(one, two);
            return result;
    class ByB implements Comparator<Item> {
        Comparator<Item> tieBreaker;
        ByB(Comparator<Item> tieBreaker) {
            this.tieBreaker = tieBreaker;
        public int compare (Item one, Item two){
            int result = one.b.compareTo(two.b);
            if (result == 0 && tieBreaker != null) {
                result = tieBreaker.compare(one, two);
            return result;
    class ByC implements Comparator<Item> {
        Comparator<Item> tieBreaker;
        ByC(Comparator<Item> tieBreaker) {
            this.tieBreaker = tieBreaker;
        public int compare (Item one, Item two){
            int result = one.c.compareTo(two.c);
            if (result == 0 && tieBreaker != null) {
                result = tieBreaker.compare(one, two);
            return result;
    }

  • Metadata searching - multiple criteria?

    Just wondering if it's possible to set multiple criteria in a metadata search? For example, imagine I have some photos where the captions include the words "Bob Jones" and some where they contain "Bob Davies". Is there any way to search for 'caption includes BOB' AND 'caption does not include JONES'.
    I appreciate that in the example above I could just search for 'Bob Davies' but this is a simplified example!

    Well the only other ones mentioned in the help are "+" at the start of a word for "starts with" and "+" at the end of a word for "ends with". There are other things I'd like to do; for example, I have photos with the following metadata in the title field:
    Photo 1: Bob Jones
    Photo 2: Bob Davies
    Photo 3: Bob Jenkins
    Photo 4: Bob Williams
    Photo 5: Bob Smith
    How can I search for Bob AND (Jones OR Davies)? Is that even possible? I know I could do it with a Smart Collection, but I find it much easier to do stuff like that with a quick text search. I often also don't need to save the results, just to see what pops up - creating a Smart Collection seems like overkill.

  • Can't 'find' using multiple criteria anymore

    Did something change in Finder such that we can't set multiple criteria for searches any more? Or is my Finder corrupt in some way?
    In a finder "Find" window, I have the search bar showing "This Mac" the current folder and the options "Contents" and "File Name" -- then there's "Save" and the little '+' icon. It used to be I could add additional search criteria by clicking the '+' (such as file visibility, extension, etc.) -- but now, clicking the '+' just opens an empty space below the existing search bar.
    Is there a 'Simple Finder' setting somewhere that got switched without my knowledge causing this? Or is my Finder borked?
    Thanks,
    Scott

    Well, I'd try moving the finder prefs file, but last night when I went to restart my MBP to deal with something else, on restart all video was gone. I even tried booting into the Apple Hardware Test on the Leopard install DVD, and while it seemed to boot up okay, there was nothing on the screen at all.
    Took it into an Apple Store this morning, and they ran a test, and found the graphics card/chip not even registering - so it looks like I'm into a new logic board. Thanks goodness I got AppleCare this time!!
    So, when I get my baby back, I'll see if the Finder issue is still there, and if so, then I'll try moving the finder prefs file out.
    Thanks,
    Scott

  • Totals Based on Multiple Criteria in Repeating Rows

    Hi All,
    I have 3 dropdowns (DD1, DD2, DD3) and one textfield (TF1) in repeating rows (not in a table).  Each dropdown has two choices and the textfield is free-form. Outside of the rows (in a different subform) I want totals based on multiple criteria from the dropdowns and textfields.
    The following script works great to get a total number of one choice from one dropdown.
    this.rawValue = xfa.resolveNodes('form1.Form.row[*].DD1.[$.rawValue == "2"]').length;
    Problem is how do I calculate the totals for the following based on the criteria listed in each row.
    Find the totals for ML
    Number of New Forms 1-2 Pages: (result should be 2)
    Number of New Forms 3+ Pages: (result should be 1)
    Number of Revised Form: (result should be 0)
    In row #1:  select “New” as a choice from DD1, “Form” as choice from DD2, “ML” as a choice from DD3 and enter “5” in TF1.
    In row #2:  select “New” as a choice from DD1, “Form” as choice from DD2 , “ML” as a choice from DD3 and enter “1” in TF1.
    In row #3:  select “New” as a choice from DD1, “Form” as choice from DD2, “ML” as a choice from DD3 and enter “2” in TF1.
    In row #4:  select “Revised” as a choice from DD1, “Series” as choice from DD2, “ML” as a choice from DD3 and enter “1” in TF1.
    In row #5:  select “New” as a choice from DD1, “Form” as choice from DD2, “PM” as a choice from DD3 and enter “1” in TF1.

    Try something like;
    var mlNewForms1or2Pages = 0;
    var mlNewFormsOver3Pages = 0;
    var mlRevisedForms = 0;
    var rows = xfa.resolveNodes('form1.Form.row[*]');
    for (var i = 0, limit = rows.length; i < limit; i++)
    var currentRow = rows.item(i);
    if (currentRow.DD1.rawValue == "1") // new
      if (currentRow.DD2.rawValue == "1") // form
       if (currentRow.DD3.rawValue == "1") // ML
        if (parseInt(currentRow.TF1.rawValue, 10) > 2)
         mlNewFormsOver3Pages++;
        else
         mlNewForms1or2Pages++;
    else // revised
      if (currentRow.DD2.rawValue == "1") // form
       if (currentRow.DD3.rawValue == "1") // ML
        mlRevisedForms++
    console.println(mlNewForms1or2Pages);
    console.println(mlNewFormsOver3Pages);
    console.println(mlRevisedForms);
    To do the same using predicates you could do;
    var mlNewForms1or2Pages = 0;
    var mlNewFormsOver3Pages = 0;
    var mlRevisedForms = 0;
    mlNewForms1or2Pages = xfa.resolveNodes('form1.Form.row.[DD1 == 1 and DD2 == 1 and DD3 == 1 and TF1 <= 2]').length;
    mlNewFormsOver3Pages = xfa.resolveNodes('form1.Form.row.[DD1 == 1 and DD2 == 1 and DD3 == 1 and TF1 > 2]').length;
    mlRevisedForms = xfa.resolveNodes('form1.Form.row.[DD1 == 2 and DD2 == 1 and DD3 == 1]').length;
    But if you wanted totals for all the permutations then this could become slow.
    Regards
    Bruce

  • Form disappears when clicking search help multiple times

    Hi All,
    I have created an interactive adobe form with Web dynpro application.
    We have multiple multiple search helps (custom and standard) on the form.
    when the user clicks on any search helps multiple times (4-5 times), the whole form disappears.
    Please provide some solution / hints.
    Best regards,
    Meep.

    We are not facing this problem on Adobe 9.4. The newest v10.1 has this problem.
    Also, this issue is only on 1 server and on other, it works fine.
    We are using Native control with ZCI layout.

  • Can I create a Formula with Multiple Products [ Not Co Products ] ?

    hi There,
    Have a simple question & Doubt.
    Is it okay to create a Formula with Multiple Products in OPM ? If Yes, how does the Formula behave with respect to Standard Costing Subledger.
    If not, what are the reasons for not creating formula with Multiple Products & what are the alternatives to that ?
    Thanks,
    Dhiraj

    hi
    U can very well define Multple products in a formula and ur std costing will work fine. But for any By products there is No costing method support. This is Oracles standard.
    Now it is clear,,,still any doubt...plz ask
    Regards
    R Singh
    Tech Mahindra Satyam

  • Search help multiple selection of search results

    Hi,
    I have a search help (SE11) and it is correctly integrated in my WDP4A application using 'automatic' search help integration. Unfortunately multiple selection of search results does not seem to be supported (the ok button greys out when >1 result is selected). Is there a standard way to link a search help to an attribute in a 0..n value node, so that at runtime a new context element is created for each selected search result? Or do I have to recreate the search help from scratch to get this behaviour (OVS)?
    If the latter is true, then why is it even possible to select multiple search results?
    Kind regards,
    Jeroen

    Hallo Jeroen,
    OVS standard configuration does not allow you to select more than one configuration, You need to specify that explicitely on Phase-0 of OVS using the set_configuration method.
    see
    [Multiple Selection in F4 help|Multiple Selection in F4 help]
    [http://wiki.sdn.sap.com/wiki/display/WDABAP/InputhelpofObjectValueSelectioninWDABAP|http://wiki.sdn.sap.com/wiki/display/WDABAP/InputhelpofObjectValueSelectioninWDABAP]
    [http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/70cee684-ccbb-2c10-3c94-91e806e5f7ac?quicklink=index&overridelayout=true|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/70cee684-ccbb-2c10-3c94-91e806e5f7ac?quicklink=index&overridelayout=true]

  • My apple I'd has been discarded for security reasons. The site asks me to give my email and they would send me the further instruction. But no Emil has arrived so far. Since January. And I did requested help multiple times. :( any ideas where can I solve

    My apple I'd has been discarded for security reasons. The site asks me to give my email and they would send me the further instruction. But no Emil has arrived so far. Since January. And I did requested help multiple times. :( any ideas where can I solve

    Who discarded the Apple ID? Apple? or You?
    Did you answer the Security Questions? Is the backup email accurate? Have you tried contacting them?

Maybe you are looking for

  • What is that means and how to fix it ,, PLZ Help

    Hello , I have FMS installed on my dedicated server Core2Due With 4g Ram and 100Mbps dediacted port ..Win 2003 standrd. I use it for live streaming but i have a problem Admin console showing this error in the application log Dropping application (liv

  • Upgraded to version 7.3 - Library file can not be saved - Unknown Error-50

    I upgraded to version 7.3 and now I get a pop up error message that says the I Tunes library file can not be saved. The program reports an unknown error occurred (-50). The Pop up error message comes up every minute or so or any time I click on any i

  • I need help choosing a cell phone

    Ok. Currently I have an HTC Eris and it has all sorts of bad issues. I have talked with Verizon on the phone, chat, in person for the last several days. They said that I can get a pre-certified phone to replace my Eris and I had been going back and f

  • WHEN-VALIDATE-ITEM Restrictions???

    How we overcome the restriction next-item,go-item under WHEN-VALIDATE-ITEM? My requirement is once something entered into text box it should validate with the database for correctness and then if info is correct then it should move to next item else

  • "BTWiFi" not listed on my iPhone 5

    When I go into Settings and then WiFi should I see BTWiFi listed when at home? All I see is the BT hub.