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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to get to know the userName

Hi all,

I want to get the user(CAL) which is currently accessing the report.

In report, I want to restrict the user dynamically, so that i do not need to use the section access.

How can i get to know while report loading, which user is accessing the report.

Thanks in advance.

10 Replies
MK_QSL
MVP
MVP

Type

=OSUSER()

in text box object

amit_saini
Master III
Master III

Hi Keshav,

Go to QMC-->Status-->QVS Statics-->Documents and Users , here you will get to know who is accessing which particular report.

Thanks,
AS

Not applicable
Author

Hi Manish,

Thanks for replying.

Let me clarify you this,

Suppose I have below two machines:

M1 - Server

M2 - CAL

Now i am trying to fetch the report via web browser.

Since the CAL is assigned for M2(Either user or machine), it will be able to access the report.

If I use osuser(), it will return me entries from M1.

But I want to know the entry for M2, as I need to restrict the CALs dynamically in the report.

I am not sure about using QVuser() in the report.

Will there be any to do so.

Thanks in advance.

ashfaq_haseeb
Champion III
Champion III

Hi,

go to chart properties --> layout --> select conditional and write below code.

if(OSUser()='<domain>\<username>',1,0)

hope it helped.

Regards

ASHFAQ

Not applicable
Author

Thanks for reply Amit.

This server side configuration I know,

but while accessing the report, I want to know in the report only, which CAL is currently accessing the report.

If there is such way, please do tell me.

Thanks in advance.

Not applicable
Author

Hi Ashfaq,

Thanks for replying.

Let me clarify you this,

Suppose I have below two machines:

M1 - Server

M2 - CAL

Now i am trying to fetch the report via web browser.

Since the CAL is assigned for M2(Either user or machine), it will be able to access the report.

If I use osuser(), it will return me entries from M1.

But I want to know the entry for M2, as I need to restrict the CALs dynamically in the report.

I am not sure about using QVuser() in the report.

Will there be any to do so.

Thanks in advance.

ashfaq_haseeb
Champion III
Champion III

Hi Keshav.

Do you use local directory or active directory to authenticate users?

Ok, do one thing use a text box and write =osuser() save you application.

now logged in to access point with m2/Cal user, tell me what does the text box return?

Regards

ASHFAQ

Not applicable
Author

Yes, I did that.

I returned me the server's user id for which qlikview server is running.

ashfaq_haseeb
Champion III
Champion III

Ok that's great.

Now from access point export the test box you see to excel.

now open the application in desktop.

go to any chart click on  properties --> layout --> select conditional and write below code.

if(OSUser()='<domain>\<username>',1,0)


<domain>\<username> replace the same with exported value.


Tell me if it works by logging in with another user.


Hope it helped.



Regards

ASHFAQ