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

Renamable Fields

We have a source application that has some custom fields.  The administrator can be show or hide these fields and configure their names.  The database names are generic.  We are building a Qlik Sense app to display data from this application.  A big focus of the Qlik Sense app will be user self-service.  We want to handle the custom fields in a way that is self-service friendly.  Using their generic names is not friendly.  We want users to be able to see the field with its defined name and add it to their visualizations where it will show up with its defined name.

Custom Field Generic Names.png

Although we could just give each custom field a new name in the load script, we don't want to break user-created visualizations if the administrator should change the name of a field in the future

We thought of trying to make master dimensions that used a variable for the dimension name.  The variable could be set in a load script. However, Sense doesn't let you use an expression for a dimension name.  We also don't want IT to have to get involved to edit master items and republish them whenever an admin changes a custom field name.  We want Qlik Sense to just pick up the change.

Can anyone suggest a way to accomplish this?

1 Solution

Accepted Solutions
scottsmp
Partner - Contributor II
Partner - Contributor II
Author

We received an answer from someone at Qlik that we talked to.  He showed us how Qlik Sense (and QlikView he said) are smart enough to handle renames without breaking existing visualizations.  If you use an AS in a load statement to rename a field, Sense keeps track of what the original source field was.  If you later rename the field in the load script while the source field remains the same, Sense knows it is the same field.  Any visualizations linked to the old name are updated to the new name so that nothing breaks.


We actually have a program that dynamically generates the load script, so changing the load script to reflect the user configured value works for us. 


If we had a static load script, using rename fields using map would be worth investigating.  As long as the rename fields command tracks name changes the same way the AS keyword does, it should work.  Since the AS will meet our needs, however, that's the solution we're going with.

View solution in original post

2 Replies
marcus_sommer

To use user-friendly fieldnames is really helpful for the users. I suggest to use a reame fields using MapTab; approach which could ensure that the fieldnames in the application are always the same even if they change in a previous process-step (the MapTab of course must be also adjusted if there are changes).

- Marcus

scottsmp
Partner - Contributor II
Partner - Contributor II
Author

We received an answer from someone at Qlik that we talked to.  He showed us how Qlik Sense (and QlikView he said) are smart enough to handle renames without breaking existing visualizations.  If you use an AS in a load statement to rename a field, Sense keeps track of what the original source field was.  If you later rename the field in the load script while the source field remains the same, Sense knows it is the same field.  Any visualizations linked to the old name are updated to the new name so that nothing breaks.


We actually have a program that dynamically generates the load script, so changing the load script to reflect the user configured value works for us. 


If we had a static load script, using rename fields using map would be worth investigating.  As long as the rename fields command tracks name changes the same way the AS keyword does, it should work.  Since the AS will meet our needs, however, that's the solution we're going with.