Convert excel code if condition to kobo code

Hello dear colleague, I hope you are well.

Need your support, I have an excel formula that I placed in column C2 to increment it later, this formula allows you to have “yes” if at least one column has a “yes” and "no " if both columns (A and B) have a “no” each, similarly “empty” if columns (A and B) are empty.
The formula looks like this: =IFERROR(IF.CONDITIONS(OR(A2=“yes”;B2=“yes”);“yes”;OR(A2=“no”;B2=“no”);“no “);””)

I wanted to convert this code into the kobo language to put it in calculate

Hi @masalafortunat, Please check this formula and let me know if it is working for you

if((${A} = “yes” or ${B} = “yes”),“Yes”,if((${A} = “no” or ${B} = “no”),“No”,“”))

a6uPoSbx9CURrGUvUnUfHS.xlsx (6.4 KB)

1 Like

@osmanburcu, :clap: :heart: :partying_face:

@masalafortunat, you should be able to learn about if-statement through this previous post:

These posts discussed previously should also be able to help you understand how it’s used.

Hello @osmanburcu thank you for your support, your Kobo formula is correct and worked well.

1 Like

Thank you @Kal_Lam for this orientation.

1 Like