Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
pgrs4219
Contributor III
Contributor III

Dimension as measure

Hi All,

I've a requirement where i have use dimension as a measure, but my that has string values so i can't use any aggr functions like sum, count exc. So currently am using Maxstring({<Category={"A"}>}OrderName) but the problem with this is when there are two records it 's only showing the largest string value because that's how this function works. But i need an expression which provides all possible values. Kindly help me here with correct formula.

Thanks in advance!

Labels (1)
2 Replies
Channa
Specialist III
Specialist III

try to write if statement in script

if (category ="a",Ordename ) as AString

 

in chart you can count

 

 

Channa
rwunderlich
MVP
MVP

You can use string aggregation functions with Aggr. 

You want OrderName values only when associated with Category=A?

Aggr(Only({<Category={"A"}>}OrderName), OrderName)

BTW, I favor "Only" but Maxstring should work with the Aggr as well.

-Rob
http://masterssummit.com
http://qlikviewcookbook.com
http://www.easyqlik.com