Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Disclaimer: I have no idea what I'm doing.

In LibreOffice Calc (3.6.2.2), I'm trying to SUM all of the values in G:x (where range is G2:G529), where B:x is equal to a given number N.

The data set that I'm working with has been derived from a list of strings - the goal is to: find all strings of length N where N is hard-coded into the query string.

Data (snippet)

Pseudocode:

If B:x is n: add G:x to SUM

Attempt (where N=1):

=SUM(IF(B2:B529, "1"), G2:G529)

Any suggestions?

PS: For the sake of semantics, assume that LibreOffice Calc == Microsoft Excel

share|improve this question

1 Answer 1

up vote 2 down vote accepted

In Excel you can use SUMIF function like this

=SUMIF(B2:B529,"1",G2:G529)

The same formula should work in Libre Office

share|improve this answer
    
Perfect, thank you. I was so close. –  Delete Feb 24 '13 at 23:19
    
To confirm: it does, indeed, work a treat in LibO Calc. Just what I needed, too. –  Davïd Dec 27 '13 at 13:10

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.