Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
abc_18
Creator II
Creator II

How to add a reference line in trend chart

Hi,

In my application I have one trend chart with drill down capabilities, in this chart I need to show reference line for target value that is based on priority.

I have added reference line under presentation tab.

how to make that reference line visible only on third level of hierarchy that is priority value??

Hierarchy is like

Domain

Track

Priority

Please suggest..

11 Replies
vinieme12
Champion III
Champion III

instead of Reference line add another expression with a condition

example

=    if( GetFieldSelection('yourgrouphere') = 'Priority', Expression)

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

try this Expression as conditional show

=GetCurrentField(yourdrilldowngroup)='Priority'

abc_18
Creator II
Creator II
Author

where do I need to write this

presentation->reference line->edit->show conditional

I tried this , but still not working

abc_18
Creator II
Creator II
Author

Hi Vineeth,

Thanks for your response, I tried your expression but not getting desired output.

Target line is appearing for all the dimensions.

vinieme12
Champion III
Champion III

Nope, not in presentation

you have to add another Expression

First > Enable conditional for the Expression

               condition : =    if( GetFieldSelection('yourgrouphere') = 'Priority', 1)


Expression = YOUREXPRESSION

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

I defined in Show conditional

if it doesnot work for you, put your Expression (60000 in example) in a TextBox

and check if the value fits to your Chart axes

abc_18
Creator II
Creator II
Author

Hi Vineeth,

I am using another formula for target line that is

Avg(SLA) in presentation tab->reference line and my expression is different.

I tried your expression under conditional tab

if( GetFieldSelections(oto drill) = Severity, 1).


but after writing this target line is not visible for any of the dimensions.

marcus_malinow
Partner - Specialist III
Partner - Specialist III

Your conditional display should be based on GetCurrentField(yourGroup)

For example:

if(GetCurrentField(yourGroup) = 'Priority', Expression)

vinieme12
Champion III
Champion III

try below  ,the function to use is GetcurrentField()


I hope Severity is the name of the Field!!


if( GETCURRENTFIELD('[oto drill]') = 'NAMEOFFIELD', 1).

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