Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am trying to get the count ID where fieldA and fieldB is not empty AND field1 is not empty OR field2 is not empty OR field3 is not empty with the below expression, but its not working:
=Count({$<fieldA =-{''},fieldB=-{''},field1 -={''}>+
<fieldA =-{''},fieldB =-{''},field2 -={''}>+
<fieldA =-{''},fieldB =-{''},field3 -={''}>} Distinct [ID] )
Are you looking to get 13?
Why don't you create a flag in the script for this
If( (Len(Trim(fieldA)) > 0 and Len(Trim(fieldB)) > 0 and Len(Trim(field1)) > 0) or
(Len(Trim(fieldA)) > 0 and Len(Trim(fieldB)) > 0 and Len(Trim(field2)) > 0) or
(Len(Trim(fieldA)) > 0 and Len(Trim(fieldB)) > 0 and Len(Trim(field3)) > 0), 1, 0) as Flag
and then this
Count(DISTINCT {<Flag = {1}>} ID)
or try this
=Count({$<fieldA = {"*"}, fieldB = {"*"}, field1 = {"*"}>+
<fieldA = {"*"}, fieldB = {"*"}, field2 = {"*"}>+
<fieldA = {"*"}, fieldB = {"*"}, field3 = {"*"}>} Distinct [ID] )
This is not feasible, as I have many conditions like this, around 20-30
This one also is not working
=Count({$<fieldA = {"*"}, fieldB = {"*"}, field1 = {"*"}>+
<fieldA = {"*"}, fieldB = {"*"}, field2 = {"*"}>+
<fieldA = {"*"}, fieldB = {"*"}, field3 = {"*"}>} Distinct [ID] )
May be try like
<FieldA={'=Len(FieldA)>0'}
Would you be able to provide a sample and explain as to what exactly are you hoping to get?
=Count({$<fieldA =-{''},fieldB=-{''},field1 -={''}>+
<fieldA =-{''},fieldB =-{''},field2 =-{''}>+
<fieldA =-{''},fieldB =-{''},field3 =-{''}>} Distinct [ID] )
Hi Sunny,
Because of security reasons I cant share the file, but the issue is not with comparing it to null as individually the output is correct but only when I am using OR condition the output is wrong.
Thanks Sasidhar, I tried this but issue is not comparing the field with null but in OR condition.
Sorry Carlo its not working.