Qlik Community

Ask a Question

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
Do More with Qlik - for Beginners and Beyond, Topic: Qlik Replicate on January 21, 2PM EST. REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Contributor II
Contributor II

OSUser - Set Analysis

I'm trying to use Set Analysis to show sales for the user who is logged in, using the following code:

sum({$<PAIDREPUser="{=SubField(OSUser(),'UserId=',2)}">}Sales)

The SubField(OSUser(),'UserId=',2) returns the user correctly and the PAIDREPUser field also returns the right name in the right format. However, when I put them together in the Analysis set I can't seem to get any result.


Any ideas what I'm doing wrong?

3 Replies
Partner
Partner

Hi Paul

Looks like your set analysis syntax is wrong

sum({$<PAIDREPUser={"=SubField(OSUser(),'UserId=',2)"}>}Sales)

your double quotes outside brackets.


Regards

Marco

MVP
MVP

sum({$<PAIDREPUser={"$(=SubField(OSUser(), 'UserId=2', 2))"}>} Sales)

May be this:

Sum({$<PAIDREPUser = {"$(=SubField(OSUser(), 'UserId=', 2))"}>}Sales)