Qlik Community

Qlik Sense App Development

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

quriouss
Contributor III

Different date formats for different users?

We are looking at rolling out Qlik Sense for a Global Audience. Our American users are used to using mm-dd-yyyy as a date format, whereas Europeans are using dd-mm-yyyy.  The data is all loaded into QlkSense in only one format.

What is a good way to deal with showing each group of users a filter box in their preferred format?  I don't really want to start re-training a nation on how to enter dates.

Can we do something with the user's LDAP/ADS profile (if UserOffice = Chicago then DateFormat=mm-dd-yyyy) or do we have to get into publishing different versions of the data for the different audiences?

Many thanks in advance for sharing your experiences.

3 Replies
lironbaram
Honored Contributor II

Re: Different date formats for different users?

hi

yes you can do something like

date(DateField , if(UserOffice = 'Chicago' , 'MM-dd-yyyy' , 'dd-MM-yyyy'))

quriouss
Contributor III

Re: Different date formats for different users?

Thanks.

Do I have to import the users as a separate stage in the load script, or can I leverage the Active Directory connection which I'm already using?  And at the risk of sounding lazy, do you happen to know the syntax/variables for Qlik to refer to the current user?

lironbaram
Honored Contributor II

Re: Different date formats for different users?

hi for the user you can use the function

osuser() which will return the current user details as

Domain\UserName

but if you need the home office i think you'll need to load the this data to your qlikview model