Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
retko1985
Creator II
Creator II

How to change variable in all objects?

Hello,

someone created template for us to use, and he uses variables with names similar to KPI displayed. Now I am using another KPI and want to change variable name in all objects. Like before it was vOrders (and it is used for conditional show etc.) and I want to change it to vSales on all objects. So everywhere it is vOrders it will be vSales.

Is it possible?

Thank you.

1 Solution

Accepted Solutions
m_woolf
Master II
Master II

You can use the Expression Overview to change in Expressions.

View solution in original post

4 Replies
jonathandienst
Partner - Champion III
Partner - Champion III

AFAIK, you have two options.

(1) Make a backup of the qvw file before doing anything. Then open the qvw file, create a -prj folder(same filename, with -prj appended), and save the document. The -prj folder will contain the complete xml layout for the document and you can do a search and replace on all (or just the relevant) XML files.

(2) Download Rob Wunderlich's Document Analyser, and run your document through the analyser. The Variables tab will show you all the expressions that use the variables, but you will have top change each expression in the normal way,

Qlikview Cookbook | Recipes for Qlikview Success

Backup!! before doing any large scale refactoring.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
m_woolf
Master II
Master II

You can use the Expression Overview to change in Expressions.

retko1985
Creator II
Creator II
Author

Hi,

do you mean to use Find/Replace here:

So for example I want to change vOrders to vSales, so I create a variable vSales with same definition as in vOrders, and then rename all vOrders to vSales in Expression Overview? It it save to do so?

Thank you.

m_woolf
Master II
Master II

Yes ... make a backup first, of course.