4

I'm working on a query in Access 2010 and need help.

  • If the value is =0 I want it to show as blank,
  • if the value is <500 I want it to show as "B",
  • if the value is >500 I want it to show as "R"
  • 1
    What do you want it to say if the value = 500? – Erik Dec 21 '15 at 20:25
7

Try:

IIf([value] = 0, "", IIf([value] < 500, "B", "R"))

IIf is a function that returns on of two values depending on the outcome of the conditional.

  • 1
    Thanks for such a fast answer! I knew about the IIF statement but I had no idea I could combine it twice like that. Now it works – Julius Dec 21 '15 at 20:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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