Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
SonPhan
Partner - Creator
Partner - Creator

Bookmarks, Is it possible to set a specific bookmark as default depending on the user?

Hello Qlik Experts,

Is it possible to set a specific bookmark as default depending on the user?

 

Means e.g. User A has the default bookmark Germany and User B has the default bookmark Austria.

 

Best regards Son

Labels (2)
2 Solutions

Accepted Solutions
vinieme12
Champion III
Champion III

Yes you can,

Filter the Country field using an expression search as below

=Country =Pick(wildmatch(OSUser(),'*userA','*UserB','*yourID'),'Germany','Austria','*')

  1. press enter to apply the filter
  2. Create the bookmark now and set it as default
  3. Save the App 
  4. This bookmark will apply filter based on the expression search based on the userid

 

 

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.

View solution in original post

vinieme12
Champion III
Champion III

I would ideally do it as below

 

Create an Island Table in your data model which has information about the User & Filter value as below for example

 

UserFilters:

Load * Inline [

User,CountryFilter

UserA,AT

UserB,DE

UserC,AT

UserC,DE

];

 

 

Create Two Variables

vUser :   =subfield(OSUser(),'UserId=',2)    //with the starting EQUAL sign

vDefaultFilter:    =concat({<User={"$(vUser)"}>}Distinct chr(39)&CountryFilter&chr(39),',')    //with the starting EQUAL sign

 

Then in the Country field apply filter as below

=Match(Country,$(vDefaultFilter))

  1. press enter to apply the filter
  2. Create the bookmark now and set it as default
  3. Save the App 
  4. This bookmark will apply filter based on the expression search based on the UserID returned from OsUser() and match it with the associated values in CountryFilter field
Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.

View solution in original post

4 Replies
vinieme12
Champion III
Champion III

Yes you can,

Filter the Country field using an expression search as below

=Country =Pick(wildmatch(OSUser(),'*userA','*UserB','*yourID'),'Germany','Austria','*')

  1. press enter to apply the filter
  2. Create the bookmark now and set it as default
  3. Save the App 
  4. This bookmark will apply filter based on the expression search based on the userid

 

 

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
SonPhan
Partner - Creator
Partner - Creator
Author

Thank you this helps me!

Have you any idea how to solve it for multiple Country?

In regular expression, this works!

SonPhan_0-1651878381774.png

But when you set it to a variable (with your logic) it doesnt recognize the filters.

SonPhan_1-1651878598028.png

Best regards Son

vinieme12
Champion III
Champion III

I would ideally do it as below

 

Create an Island Table in your data model which has information about the User & Filter value as below for example

 

UserFilters:

Load * Inline [

User,CountryFilter

UserA,AT

UserB,DE

UserC,AT

UserC,DE

];

 

 

Create Two Variables

vUser :   =subfield(OSUser(),'UserId=',2)    //with the starting EQUAL sign

vDefaultFilter:    =concat({<User={"$(vUser)"}>}Distinct chr(39)&CountryFilter&chr(39),',')    //with the starting EQUAL sign

 

Then in the Country field apply filter as below

=Match(Country,$(vDefaultFilter))

  1. press enter to apply the filter
  2. Create the bookmark now and set it as default
  3. Save the App 
  4. This bookmark will apply filter based on the expression search based on the UserID returned from OsUser() and match it with the associated values in CountryFilter field
Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
SonPhan
Partner - Creator
Partner - Creator
Author

Hello, 

this works thank you!