Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
If extra person in room is child then charge is zero and remaining adult in room number charge should change to zero ,i need Sum(aggr(sum(distinct(charge )),room number . as required 2nd table
Hi, I think the expression could be something like: Sum(Aggr(IF(Index(Concat(TOTAL <ROOM> AC),'CHILD'),0,Sum(DISTINCT CHARGE)),ROOM))
Maybe it need to add the condition for extra person.
For a room charge, it will be better to have it precalculated in script so the expression in the front end will be easier and give better performance.
Any script level suggesion
Too few info. The objective would by to create a table by room (maybe by and id that identifies the reserve) and the charge associated to that reservation (maybe only for the extra person) so you only need a sum of this RoomCharge