expression error

Hi all,

I have a huge problem in which I'm stuck and I'll explain to you hoping that someone can give me a hand.

I need to create a control on several inserted fields and have a result.

I explain :

- I have a field named "season" which can take on two values -- ( Hight and Low) 

- if the value is "high" I have to check the "room" field 

- for each room it gives me a numerical value

- different from the season loss

I have try with : 

IF (

AND([SEASON]="hight",

IFS([room]="double",100,[room]="triple",200,[room]="quad",300) ),0)

But it doesn't work...how can i do it if i want to chain?

IF(..IF(..IF(..)))

Solved Solved
0 6 190
2 ACCEPTED SOLUTIONS

I may try the following:

IF (

AND([SEASON]="hight", IN([room],{'double','triple','quad'})),

IFS([room]="double",100,[room]="triple",200,[room]="quad",300),

0

)

View solution in original post

IF (

AND([SEASON]="hight", IN([room],{'double','triple','quad'})),

IFS([room]="double",100,[room]="triple",200,[room]="quad",300),

IF (

AND([SEASON]="loss", IN([room],{'double','triple','quad'})),

IFS([room]="double",100,[room]="triple",200,[room]="quad",300),

0

)

)

View solution in original post

6 REPLIES 6

Aurelien
Google Developer Expert
Google Developer Expert

@peppemigl wrote:

how can i do it if i want to chain?


Hi @peppemigl 

I would suggest to mix together IFS() and AND()

I may try the following:

IF (

AND([SEASON]="hight", IN([room],{'double','triple','quad'})),

IFS([room]="double",100,[room]="triple",200,[room]="quad",300),

0

)

fantastic , 

IFS([room]="double",100,[room]="triple",200,[room]="quad",300),

0) 

it's possible to insert another AND e IFS for season "loss"?

replace the 0 with another IF() or IFS() expression.

IF (

AND([SEASON]="hight", IN([room],{'double','triple','quad'})),

IFS([room]="double",100,[room]="triple",200,[room]="quad",300),

IF (

AND([SEASON]="loss", IN([room],{'double','triple','quad'})),

IFS([room]="double",100,[room]="triple",200,[room]="quad",300),

0

)

)

thanks so much😊

Top Labels in this Space