openoffice calc. There is another way to do sumif? - openoffice-calc

How could you do this differently. shorter ?
=SUM(IF(G52>F52))+SUM(IF(H52>G52))+SUM(IF(I52>H52))+SUM(IF(J52>I52))+SUM(IF(K52>J52))+SUM(IF(L52>K52))

This formula produces the same results:
=(G52>F52)+(H52>G52)+(I52>H52)+(J52>I52)+(K52>J52)+(L52>K52)

I think this also produces the same result:
=SUM(G52:L52>F52:K52)
entered with Ctrl+Shift+Enter

Related

How do I get my regexextract forumula to work in google sheets?

I'm trying to use regexextract on a list of cells in google sheets. I've tested the regular expression and it works for the string I'm trying to extract, but when I use it in google sheets, it seems to be splitting the output into a few different columns.
I tried using this formula:
=REGEXEXTRACT(C107,"[+-]?([0-9]*[.])?[0-9]+X[+-]?([0-9]*[.])?[0-9]+X[+-]?([0-9]*[.])?[0-9]+")
and was expecting this string:
WASHER SS 3.2X6X0.5 A4
to output:
3.2X6X0.5
But instead I was getting:
3. [Blank column] 0.
Split into 3 cells. Hope I've explained this problem clearly enough, and thanks in advance for reading this!
You can use:
=REGEXEXTRACT(C107,".+ (\d.+) ")

RegexExtract Syntax - Extract text after decimal/number from string ex. "UNDER 12.5-120"

I am trying to write a RegexExtract formula to extract the odds of a bet.
My example text is UNDER 12.5-120.
In this example, I would hope to return -120 but I need my equation to be dynamic enough to extract other odds as well.
More examples of this would be +120, +1200, +12000, -1000, etc etc.
The string will always be in this order though - OVER or UNDER then the line of the bet and then the odds of the bet. I have successfully written the regex for the line and the over/under but cant figure out the odds portion.
This is what I have so far:
=REGEXEXTRACT('Form Responses 2'!C2,"[\d.,].*") but this returns 12.5-120 and I need only the -120.
Try this for a range
=INDEX(IFERROR(REGEXEXTRACT(Q2:Q8,"[-|+]\d+")))
If you want to have pure numbers try
=INDEX(IFERROR(REGEXEXTRACT(Q2:Q8,"[-|+]\d+")+0))
This ended up working for me!!!
=REGEXEXTRACT('Form Responses 2'!C2,"[-|+][\d]+")

Google sheets - Conditional Formatting "less than" not working properly when used on range

t Hey guys, im getting mad about something really simple. Why does this plain conditional formatting light up the values 15 and 12? When applied only for cell D1 or F1 it works properly, I'm really clueless. Thank you for your advice!
Also my greetings got deleted everytime after saving the edit, I had to put a random letter in front so it got through, whats up with that random behaviour lol
instead of your:
=A1
use:
=$A1

TO_PURE_TEXT with cell referencing doesn't filter double quotes against documentation

I want to get a clean number from a string like "123.45". On using of =TO_PURE_TEXT(C10) it doesn't work for me,
against an example from the documentation. An absolute referencing doesn't help.
But, if i use no cell referencing, but direct input, like =TO_PURE_TEXT("123.45") the input is correct, as expected without quotes.
Is it a kind of bug, or do i really do something wrong? How can i get this work with the cell referencing?
all you need is:
=SUBSTITUTE(C10, """", )*1
or:
=REGEXREPLACE(C10, """", )*1
I can't speak to whether it's a bug. Does seem odd, but this should work for now:
=1*SUBSTITUTE(C10,CHAR(34),"")

If function - equal/different/blank

I'm trying to write an formula that will give me the following result:
IF H1=H2, write "OK", if they are different, write "NO", if H1 is blank, then become blank too.
I tried like this:
=IF(H1=H2;"OK";"NO";IF(H1="";""))
And it says I've entered too many arguments for this function.
Any advice?
You added an extra ;, try this:
=IF(H1="";"";IF(H1=H2;"OK;"NO"))
Solved like this
=IF(H1="","",IF(H1=H2,"OK","NO"))
Thankyou everyone