Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a master measure that sums different counts like:
Count(condition1, key_id) + Count(condition2, key_id2) + ...
I use it in a total column from a table.
How could I avoid double counting key_ids that I already count in previous conditions.
Thanks.
May be try this
=Count({$<[test_product]={'FTTC3'}, [speed_brag_v1]={'Excellent','Good','Very Good'}, [stability_brag_v2]={'Blue','Green','Pink'}>+
$<[initial_lt_diagnosis_code]={'GTC_FTTC_SERVICE_1202','GTC_FTTC_SERVICE_1203','GTC_FTTC_SERVICE_1204'}>+
$<[OUTCOME_CODE]={'ASSOCIATE_1000', 'ASSOCIATE_1002', 'ASSOCIATE_1003'}>+
$<[initial_lt_diagnosis_code]={'GTC_FTTC_SERVICE_1614'}>+
$<OUTCOME_CODE={'GTC_TEST_4006','GTC_TEST_3002','GTC_TEST_4004','GTC_TEST_4002','GTC_TEST_3001','GTC_TEST_4001','GTC_TEST_4019','GTC_TEST_4005','GTC_TEST_4020','GTC_TEST_4021'}>+
$<[ds_line_rate_at_product_cap]={'Y'}>}[siebel_fault_id])
Can you share your full expression to look into?
Count({$<[test_product]={'FTTC3'}, [speed_brag_v1]={'Excellent','Good','Very Good'}, [stability_brag_v2]={'Blue','Green','Pink'}>}[siebel_fault_id])+
Count({$<[initial_lt_diagnosis_code]={'GTC_FTTC_SERVICE_1202','GTC_FTTC_SERVICE_1203','GTC_FTTC_SERVICE_1204'}>}[siebel_fault_id])+
Count({$<[OUTCOME_CODE]={'ASSOCIATE_1000', 'ASSOCIATE_1002', 'ASSOCIATE_1003'}>}[siebel_fault_id])+
Count({$<[initial_lt_diagnosis_code]={'GTC_FTTC_SERVICE_1614'}>}[siebel_fault_id])+
Count({$<OUTCOME_CODE={'GTC_TEST_4006','GTC_TEST_3002','GTC_TEST_4004','GTC_TEST_4002','GTC_TEST_3001','GTC_TEST_4001','GTC_TEST_4019','GTC_TEST_4005','GTC_TEST_4020','GTC_TEST_4021'}>}[siebel_fault_id])+
Count({$<[ds_line_rate_at_product_cap]={'Y'}>}[siebel_fault_id])
I was trying something like Count( Distinct IF(condition1 OR condition2....), [siebel_fault_id])
I have each 'count' in a different master measure if it helps
May be try this
=Count({$<[test_product]={'FTTC3'}, [speed_brag_v1]={'Excellent','Good','Very Good'}, [stability_brag_v2]={'Blue','Green','Pink'}>+
$<[initial_lt_diagnosis_code]={'GTC_FTTC_SERVICE_1202','GTC_FTTC_SERVICE_1203','GTC_FTTC_SERVICE_1204'}>+
$<[OUTCOME_CODE]={'ASSOCIATE_1000', 'ASSOCIATE_1002', 'ASSOCIATE_1003'}>+
$<[initial_lt_diagnosis_code]={'GTC_FTTC_SERVICE_1614'}>+
$<OUTCOME_CODE={'GTC_TEST_4006','GTC_TEST_3002','GTC_TEST_4004','GTC_TEST_4002','GTC_TEST_3001','GTC_TEST_4001','GTC_TEST_4019','GTC_TEST_4005','GTC_TEST_4020','GTC_TEST_4021'}>+
$<[ds_line_rate_at_product_cap]={'Y'}>}[siebel_fault_id])