to get now a distinct for the tags and the number of elements i use
"SELECT DISTINCT s.Text as Tag, " +
"COUNT(s) as Count " +
"FROM " + context.Name.AddGraveAccent() + " " +
“d UNNEST d.Tag AS s WHERE d.Type =’” + typeof(tt).Name + "’ " +
“AND s.Text IS NOT NULL Group by s”;
and i will get a result for each tag and their count:
a, 2,
b, 2,
c, 1,
…
I know that unnest is not possible with cblite but maybe someone has an idea how to approach this result also in cblite!