Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
IMPORTANT: Upcoming LEF Database Maintenance, Oct. 3rd - SEE DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

os user

Hi,

I'm trying to get the operation system user name by using the funtion OsUser() in the load script.

The problem is that the user that I got is Administrator, because the reload done automaticly by the server.

How can I get the real Operation System user (Client user).

Thanks!

Itsik

7 Replies
Highlighted

Itsik

Unfortunately one cannot get the client os oser.

Best Regards,     Bill

Highlighted
MVP
MVP

QV does not get reloaded client wise. So you can't get client user in the script. If you want client user, you can get it in the UI using the same function.

Highlighted

Trescesco

Are you saying that one can get the End User Client o/s user name [and not that of the [QV Server] returned into the dashboard qvw and then used in dashboard expressions ?

It would be great if that was the case.

Best Regards,     Bill

Highlighted
MVP
MVP

Hello Bill,

Yes.

try, OsUser() function in a text box and see it in the browser.

Highlighted
Creator III
Creator III

the function will return your domain and userid, not your user name.

my id is 'DKO' and username is 'Dirk Konings'

If you also read the AD tables, you could get the actual name out of there.

Regards

Dirk

Highlighted
Not applicable

what is the AD tables?

Highlighted
Creator III
Creator III

Active Directory tables.

add this to connect:

CONNECT TO 'Provider=ADsDSOObject';

and something like this to retrieve the data

SQL select  name, distinguishedName, sAMAccountName, mail, userAccountControl, telephoneNumber
FROM 'LDAP://$(RootDse)'  WHERE objectCategory='Person' and objectClass = 'user'

where RootDse is your domain grouping name as found in LDAP

Dirk