Sheets - Sum using 2 conditions with same email

I have a data like this.

I want to get the sum of the data in Sheets with this condition

  1. For OLD BOOKING - When the email has type of 'NEW" and “OLD” (Same email has NEW and OLD type) example is [email protected] and [email protected] (where sum is 2)

  2. For EXPIRED BOOKING - When the email has type of 'NEW", “OLD” and “EXT” (Same email has NEW and OLD and EXT type) example is [email protected] (only 1)

Thanks!

IMG_20220818_183437_736

Hi @zocket, this sounds like a super specific question, so there’s no pre-built node for that.

You can, however, use a bit of JS to first identify the unique EMAIL values and then check for each condition. For example like so:

Result:

Hope this helps!

2 Likes

Thanks @MutedJam, Quite helpful :raised_hands:

1 Like

No worries at all, glad to hear this helps :slight_smile: