Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8085119
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T18:00:46+00:00 2026-06-05T18:00:46+00:00

In Google Docs (which shares many commands with excell and other spreadsheet programs) there

  • 0

In Google Docs (which shares many commands with excell and other spreadsheet programs) there are functions:

  • SUMIF: takes a predicate, anda range, and adds up all items in the predicate that meet thepredicate.
  • SUMPRODUCT: takes 2 column ranges, on each row multiples the element by the element next to it in ther other range, then adds all these up.
+-----+-----------------+------+------------------+
| qty |     product     | item | item per product |
+-----+-----------------+------+------------------+
|   4 | box of foo      | foo  |               10 |
|   8 | foo             | foo  |                1 |
|   2 | box of bar      | bar  |               10 |
|   1 | foorbar package | set  |                1 |
+-----+-----------------+------+------------------+

So I have an order list (basically inventory), of products.
Each product contains one or more items.
Most of the time is is just of a single typ of item.
Except the foobar package which contains 1 foo and one bar.

I want to generate a table summerizing how many
of each item we are ordering.
which would like:

+------+----------------+
| Item |    Net Qty     |
+------+----------------+
| foo  | 49 (=4*10+8+1) |
| bar  | 29(=2*10+1)    |
+------+----------------+

The stuff in brackets is not part of the output table, just htereto make it clear where each number comes from.

How can I generate such a table?
It seems like it could be acomplished by using If, Sum and Product.
Using Ifs to make it count things that don’t have the name of matching either the item I’m countering of the keyword “set”, as zero,
and then SUMPRODUCTING the result.
But i[m not sure how to accomplish this in one line

I’m not very cluey about If, or doing complex things in spreadsheets in general

This is a one off thing so i don’t want to go to the effort of creating a database, then exporting a speadsheet.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T18:00:47+00:00Added an answer on June 5, 2026 at 6:00 pm

    inspired by this blog, this works for your data:

    =arrayformula(sumproduct(
     (($C$2:$C$5="foo")+($C$2:$C$5="set")), $A$2:$A$5, $D$2:$D$5))
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to load a spreadsheet formatted in CSV directly from Google Docs.
How can I use GOOGLE DOCS in my project which I am doing using
I use Google Docs to handle some documents, which i display on my website
I'm writing a program which must download documents from google docs. I have downloaded
I have the requirement to embed a Google Docs spreadsheet on a webpage, but
Google docs app uses swipable gesture based tabs using which you can navigate to
I need to create an application which is similar to google docs. I have
I have a Web page in which I embed a Google docs viewer in
I previously posted this question ( Reading Google docs spreadsheet ) and got a
I have a Google Docs spreadsheet with a few columns. In column D I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.