[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

issue with excel formula

Posted on 2011-10-01
5
Medium Priority
?
189 Views
Last Modified: 2012-08-14
Hello all

I have an issue with a formula in one cell:
=+SI(ESTVIDE(D9),"-",SI(D9="-","-",SI(D9>=2%,"B",SI(D9>=0,"G",SI(D9>=-1%,"A",SI(D9>=-2%,"R"))))))

Open in new window


This formula is in cell column E.

So if for example, in cell B of the same row, i have the value: 1546

And in column C: 1472
then, in column D, i have a formula : =(C12-B12)/B12
That will give the result: -5%

So with the big formula where i have an issue, i should get the result "G"
But i have FALSE.

But if i change the formula =(C12-B12)/B12 with the real result -5%, then, it give me the result G.

Can you help me with that?

Thanks

test.xlsx
0
Comment
Question by:Wilder1626
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 37

Expert Comment

by:Neil Russell
ID: 36896482
Because cell D12 contains a formula that gives a numeric answer. All you have done is changed the display format so it SHOWS -5%

Your compares need to be again actual values.

=IF(ISBLANK(D12),"-",IF(D12="-","-",IF(D12>=0,"B",IF(D12>=0,"G",IF(D12>=-0.01,"A",IF(D12>=-0.02,"R","Out of Range"))))))
0
 
LVL 19

Accepted Solution

by:
regmigrant earned 1000 total points
ID: 36896531
The final part of your formula

SI(D9>=-2%,"R") does not have a 'False' condition so excel is returning 'False' which is correct because D9 is NOT greater than or equal to -2%.( -5% is LESS than -3%.)
your formula will return 'false' for any number less than -2%

to get a G returned from this formula you would have to have a number slightly more than 0 and slightly less than 2

Without knowing what you are trying to achieve its difficult to advise further but the following might help you understand where your problem lies

=IF(OR(ISBLANK(D12),D12="-"),"-",IF(D12>=2%,"B",IF(D12>=0,"G",IF(D12>=-1%,"A",IF(D12>=-2%,"R","other")))))





0
 
LVL 50

Assisted Solution

by:barry houdini
barry houdini earned 1000 total points
ID: 36896592
Neilsr,

It isn't a problem to compare against percentages - the test =D12>=-2% is as valid as =D12>=-0.02

I agree with regmigrant, -5% doesn't fall into any of the categories specified, hence FALSE. I think that happens whether -5% is returned by the formula or manually inserted.

Perhaps you can specify in words what you want the formula to do, Wilder1626

regards, barry
0
 
LVL 11

Author Closing Comment

by:Wilder1626
ID: 36896627
Thanks to both of you, since R is my last result i can get, i have changed it to SI(D12>=-100%,"R") instead of SI(D12>=-2%,"R").

Thanks again
0
 
LVL 19

Expert Comment

by:regmigrant
ID: 36906377
just a style point on your final comment - if D12 is ever lower than -100% you will get False again. If you are sure this can't happen its ok but from an elegance point of view you dont need the final 'Si', if you always want to return "R" at this point you can just put "R" because there is no other result
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When you see single cell contains number and text, and you have to get any date out of it seems like cracking our heads.
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question