AnsweredAssumed Answered

SQL: How to count distinct values with field containing multiple values

Question asked by openspace on Feb 24, 2015
Latest reply on Feb 26, 2015 by nicolai

Hello is there a SQL calc that can count a list of distinct values where each field can have one or more values separated by a ¶?

 

Right now I'm using: ExecuteSQL ("SELECT COUNT (DISTINCT Field) FROM Table" ; "" ; "")

but this only counts the first value of a field that contains two values giving me an incorrect result (example below would incorrectly result: 4)

 

Example:

a¶b

a¶b

c

d

d

e¶f

e

 

I would like the result to display a count of =6

 

Outcomes