Forum Discussion

adam_macs's avatar
adam_macs
Icon for Helper I rankHelper I
3 years ago
Solved

Subgroup analysis returning TRUE when Blank

Hi all, I have created a column that looks up the Customer Group column and returns true/false if any customer within that group has purchased (even if only one or two purchased).    My formula see...
  • FreemanZ's avatar
    3 years ago

    this shall also work:

    IsGroupCustomer = 
    VAR _condition1 =
    COUNTROWS(
        FILTER(
            TableName,
            TableName[Customer Group] = EARLIER(TableName[Customer Group])
                &&TableName[Purchase]
        )
    )>=1
    VAR _condition2 =
    TableName[Customer Group]<>BLANK()
    RETURN
    IF(
        _condition1&&_condition2,
        TRUE, FALSE
    )