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: 
Not applicable

Highlight fields in table

Hi there,

I wonder if you can help,

I would like to highlight values in a table (without filtering the table).

So, for example, if I select customer 'John Smith', is it possible to highlight all orders made by John in a table?

I do not want to filter the whole table, rather just highlight the rows that are related to John Smith,

Thanks

8 Replies
tresesco
MVP
MVP

See if this helps: Force selection in listbox

Anonymous
Not applicable
Author

t do you mean, that you select John Smith

Selecting a field, the table reduces to those rows belonging to this field

so you would only see orders made by John Smith.

can you Elaborate more what you want?

Not applicable
Author

Hi there,

no, I do not want to reduce the table fields. I only want to highlight those fields that are relevant to the customer that has been selected.

So with the below example, I still want to see all the data, but, i want 'john smith' records to be highlighted

Order ID     Name    

281            John Smith

282            Carl Smith

287            Joe smith

223            John Smith

petter
Partner - Champion III
Partner - Champion III

If you click on the + to the left of an expression in the expression tab or the + to the left of a dimension in the dimensions tab for you charts properties you will see background color and you can define a definition for it which could look like this:

If( Customer = 'John Smith' , Yellow(100) )

This will make a light yellow background color in the cells for that particular column when the "value" is 'John Smith'.

If you want to have this more interactive you can create an Input Box with the variable v.HightLight_Customer

and then modify the definition for the background color to this:

If( Customer = '$(v.HighLight_Customer)' , Yellow(100) )

This will allow you to write the name of the customer and get this customer highlighted ...

Not applicable
Author

Thanks Petter,

Ideally I would like to be able to do this based on the search box.

So, if the client searches "John Smith" the entire dashboard should update with his details.

I need this particular pivot table to behave slightly differently, as it should just highlight rows (data should not alter).

So, is there a way to alter your expression to say "if dropdown box = "john smith" then highlight rows"

jonathandienst
Partner - Champion III
Partner - Champion III

You will have to modify the table expressions (and any calculated dimensions) to ignore the selection (so that the selection does not hide the other rows), then add a a style and/or colour expressions to the expressions

Override specific selections in your expressions with the set expression syntax    =Sum({<Field1=, Field2=>} ....)

For the colour expression

=If(Wildmatch(Concat(Field1, '|'), '*' & Field1 & '*'), LightRed())

Now if  selection(s) of Field1 is/are made, then the selected values will change from the default colour to light red.

This works if the selections are dimensions in the table, but may give odd results if the field with selections is not part of the dimensions or closely related to the dimensions.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Not applicable
Author

Thanks Jonathan,


I think I am almost there.

I have added the highlighting as you suggest.

When the customer name is selected, I do not want the data shown to be reduced / changed - just the field highlighted.

However, if I were to select "location" then I would want the data updated in the table to show customers in 'London' and then 'John Smith's" records should be highlighted.

Any idea how to add that kind of logic?

Not applicable
Author

Is anyone able to help?