Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

QlikSense - Vertical Table

Hi guys!

I'm hoping to tap into your vast knowledge.

I have a tab in Sense where I would like to display a summary of attributes for the specific selection, i.e. one row per field.

Using a table this results in each field being displayed horisontally and the data in a row beneath. Thus:

2017-01-12 14-31-50.png

What I would like is to have it displayed like this:

2017-01-12 14-31-57.png

Is there a way to do this in QlikSense? Have I missed something obvious?

Thanks, guys 😃

//Nathalie

1 Solution

Accepted Solutions
petter
Partner - Champion III
Partner - Champion III

It is somewhat possible to do it in Qlik Sense with the normal table - not with dynamic number of columns though. So this might be too much of a hack for you - but it does work.

 

  1. Create a variable like this:
    2017-01-12 18_00_46-Qlik Sense Desktop.png
    ='ValueList(' & Chr(39) &  Concat( {<$Table={Sales}>} $Field ,Chr(39)&','&Chr(39)) & Chr(39) & ')'

  2. The first column has to be this expression:
    =$(SalesFields)
  3. The second column has to be this:
    =FieldValue($(SalesFields) , 1 )
  4. The third column has to be this:
    =FieldValue($(SalesFields) , 2 )
  5. .... and so on ....

     And you have to add the columns manually but just increase the second parameter by one for each new column.

The limitation is that there is no real sorting as every field value will come in load order as it is in your load script. Of course you can manually sort by doing the FieldValue index descending instead ....

Here is my [Sales] table flipped over:

2017-01-12 18_04_43-Inbox - Petter.Skjolden@qlik.com - Outlook.png

An extension like Bill suggested would be easier to use... If you need something today that works and you can live with the limitations this recipe will work....

View solution in original post

11 Replies
Anonymous
Not applicable
Author

I could not find a way of doing this with Out Of the Box QlikSense, so am writing an extension to do it.

Not applicable
Author

OK, Bill! Keep me posted =).

petter
Partner - Champion III
Partner - Champion III

It is somewhat possible to do it in Qlik Sense with the normal table - not with dynamic number of columns though. So this might be too much of a hack for you - but it does work.

 

  1. Create a variable like this:
    2017-01-12 18_00_46-Qlik Sense Desktop.png
    ='ValueList(' & Chr(39) &  Concat( {<$Table={Sales}>} $Field ,Chr(39)&','&Chr(39)) & Chr(39) & ')'

  2. The first column has to be this expression:
    =$(SalesFields)
  3. The second column has to be this:
    =FieldValue($(SalesFields) , 1 )
  4. The third column has to be this:
    =FieldValue($(SalesFields) , 2 )
  5. .... and so on ....

     And you have to add the columns manually but just increase the second parameter by one for each new column.

The limitation is that there is no real sorting as every field value will come in load order as it is in your load script. Of course you can manually sort by doing the FieldValue index descending instead ....

Here is my [Sales] table flipped over:

2017-01-12 18_04_43-Inbox - Petter.Skjolden@qlik.com - Outlook.png

An extension like Bill suggested would be easier to use... If you need something today that works and you can live with the limitations this recipe will work....

Not applicable
Author

Hi Petter

Thanks! I only have the one column (after field name) for this so that could work a charm.

I got it working for the Field but not the content. The ressult looks like:

The settings:

Do you Think you can help me?

Cheers

//Nathalie

petter
Partner - Champion III
Partner - Champion III

It is important that you do step one in my recipe - create the variable Fakta_1 (in your case).

Did you do that?

The variable should be defined like this - I guess your table is called Fakta?

='ValueList(' & Chr(39) &  Concat( {<$Table={Fakta}>} $Field ,Chr(39)&','&Chr(39)) & Chr(39) & ')'



Is it a count or sum you want to do for each Rubrik?

Not applicable
Author

Hi Petter

Yes. All steps are accounted for =).

I only want to show the value for each field. The value is to 99% of the time non-numerical.

Not applicable
Author

Hi!

I found my mistake.

I had made two semi-identical variables with the same name, which confused everything of course. Now it works perfectly. Thanks a bundle, Petter!

sskinner
Contributor II
Contributor II

Hi, I checked the Qlik Branch for something like this but could not find anything (?). This works very well,  I just needed a little extra bit of functionality: the displayed 'row' to be based on current selections (most likely a single row).  Conceptually something like;
=FieldValue($(SalesFields) , CurrentlySelectedRowNo() )

What I ended up doing to solve this is storing the RowNo in a field in the table (although I think it is in there already) and then doing this...
=FieldValue($(SalesFields) , Only({$}[KeyRowNoField]))

It seems to be working 🙂.  Just sharing in case it's of use or someone has a better way. Update: which "almost" works; seems to not return all values. Could be my data...

kpradeep5610
Contributor III
Contributor III

Hi Petter,

Excellent solution you are provided. but my requirement is if i select any field in that table it wont reflect to the table.