Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to Use self defined Variable in visualisation

Hi,

I followed the video to create a Variable --vProfit successfully, but I can not find it in the list

http://help.qlik.com/en-US/sense/September2017/Content/Videos/Videos-adding-variable-from-assets.htm

here is the variable i created.

Screen Shot 2017-11-01 at 10.32.21.png

Screen Shot 2017-11-01 at 10.31.59.png

Want to use it in the line chart or scatter plot

but can not find it anywhere

I also tried to Create a Column or say a measure --iProfit (same expression)

was assume Qliq will create a Column for this measure     for each row. But it is not, I only have 1 point at last

Any one can help?

Any instruction? Thank you!

1 Solution

Accepted Solutions
Mark_Little
Luminary
Luminary

HI Again,

As Mark has suggested. Take a step back and make sure your expressions is working correctly.

From your last message, it sounds like you have you measure created. Try adding this to a KPI object or other chart and see if you are getting results.

If it is working, then you can just reuse the expression from the master items instead of adding to a variable.

Mark

View solution in original post

4 Replies
Mark_Little
Luminary
Luminary

Hi

Normally you would need to dollar expand to get the result of the expression.

So $(vProfit)

I would start by putting the variable into a text field and make sure are getting a result.

Mark

Anonymous
Not applicable
Author

Hi Mark,

Sorry did not really get how I could use this.

And I was use ''MasteItem'' --> Create a 'Meausre' and I use the Function

profit = Sales-Cost


then still the result is not right......

rittermd
Master
Master

Sounds like you are really confused.

Forget the variable for now.

Create a bar chart for example.  Use something as your dimension that makes sense.  For your measure use the fx to enter the editor and type in Sales-Cost assuming these are the field names you are using in your data.

You should now see a bar chart with the correct data and measure.

If that worked then you can try making the expression a variable if you need to and using that instead.

Mark_Little
Luminary
Luminary

HI Again,

As Mark has suggested. Take a step back and make sure your expressions is working correctly.

From your last message, it sounds like you have you measure created. Try adding this to a KPI object or other chart and see if you are getting results.

If it is working, then you can just reuse the expression from the master items instead of adding to a variable.

Mark