I need help to figure this out

%3CLINGO-SUB%20id%3D%22lingo-sub-1318625%22%20slang%3D%22en-US%22%3EI%20need%20help%20to%20figure%20this%20out%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1318625%22%20slang%3D%22en-US%22%3E%3CP%3Ewhat's%20wrong%20with%20this%20formula%20%3D%20IF%20(B9%26gt%3B%200)%2C%20%22QUOTIENT%20(B9%2C%20G9)%22%20%3F%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1318625%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1318679%22%20slang%3D%22en-US%22%3ERe%3A%20I%20need%20help%20to%20figure%20this%20out%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1318679%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F627639%22%20target%3D%22_blank%22%3E%40Oscarcasadiego%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAssuming%20that%20where%20B9%20is%20greater%20than%20zero%2C%20you%20want%20the%20text%20result%20'QUOTIENT%20(B9%2C%20G9)'%2C%20you%20simply%20have%20a%20closed%20parentheses%20in%20the%20wrong%20place.%26nbsp%3B%20For%20good%20order%2C%20you%20should%20also%20include%20a%20result%20if%20the%20logical%20test%20is%20false%20(i.e.%20B9%20is%20equal%20to%20or%20less%20than%20zero)%20-%20try%20this%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3DIF(B9%26gt%3B0%2C%22QUOTIENT%20(B9%2C%20G9)%22%2CFALSE)%26nbsp%3B%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1319238%22%20slang%3D%22en-US%22%3ERe%3A%20I%20need%20help%20to%20figure%20this%20out%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1319238%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F627639%22%20target%3D%22_blank%22%3E%40Oscarcasadiego%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20addition%2C%20quotes%20are%20not%20needed.%3C%2FP%3E%0A%3CP%3EAs%20variant%20that%20could%20be%20also%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%3DIFERROR(MAX(0%2CQUOTIENT(B9%2CG9))%2C0)%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3Ewhich%20returns%20zero%20for%20negative%20B9%20and%20if%20divide%20on%20zero%20(G9).%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
Visitor

what's wrong with this formula = IF (B9> 0), "QUOTIENT (B9, G9)" ??

2 Replies
Highlighted

@Oscarcasadiego 

 

Assuming that where B9 is greater than zero, you want the text result 'QUOTIENT (B9, G9)', you simply have a closed parentheses in the wrong place.  For good order, you should also include a result if the logical test is false (i.e. B9 is equal to or less than zero) - try this:

 

=IF(B9>0,"QUOTIENT (B9, G9)",FALSE)  

Highlighted

@Oscarcasadiego 

In addition, quotes are not needed.

As variant that could be also

=IFERROR(MAX(0,QUOTIENT(B9,G9)),0)

which returns zero for negative B9 and if divide on zero (G9).