Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
manmade
Contributor II
Contributor II

Put a specific value at the first column in pivot table

Hi,

I need to put a specific column at first in a pivot table regardless of any other column in pivot table. I tried to use sort by expression but it is not working. I used Match(col_name, 'A', 'B',...) where I need 'A' to be the first column always. Is there way to do it?

1 Solution

Accepted Solutions
Andrei_Cusnir
Specialist
Specialist

Hello,

 

Your use case scenario most probably is not supported, so you might have to submit a feature request [1]. However, there might be a workaround that you can use:

 

1. I have the following Pivot table that I constructed from fake dataset that I found online:

IMAGE

 

2. Now if you try adding new row under Dimensions > Row:

IMAGE

 

You will notice that it adds another row under Products, which is not what you are looking for.

 

3. If you try adding new column under Dimensions > Column:

IMAGE

 

You will notice that it just adds the values under each Fruit, which is also not what you need.

 

4. Finally, if you try adding new measure under Measures > Values:

IMAGE

 

You will notice that it splits each Fruit into two sections, which also doesn't meet your needs.

 

5. As you can see, natively adding a custom column in the beginning of the Pivot table, seems to be unsupported for now, so you can submit a feature request [1] to have it as an option.

 

6. However, a work around that might help is to go and edit the first dimension, under Dimensions > Row

7. Instead of having the expression as =[Product], you can add it as =[Product] & ' (Specific Value)'

8. The output is:

IMAGE

 

While it doesn't add an additional column as you want, it does add custom values next to the dimension's values. So it might at least help you achieve the view of the table that you are looking for.

 

I hope that this information was helpful. In case I have misunderstood the use case scenario, please elaborate in details by providing additional information. However, if it has helped you resolve the issue, please mark it as accepted solution to give further visibility to other community members. 

 

---

[1] https://community.qlik.com/t5/Knowledge/How-To-Submit-Feature-Requests-For-Qlik-Products/ta-p/171258...

Help users find answers! Don't forget to mark a solution that worked for you! 🙂

View solution in original post

1 Reply
Andrei_Cusnir
Specialist
Specialist

Hello,

 

Your use case scenario most probably is not supported, so you might have to submit a feature request [1]. However, there might be a workaround that you can use:

 

1. I have the following Pivot table that I constructed from fake dataset that I found online:

IMAGE

 

2. Now if you try adding new row under Dimensions > Row:

IMAGE

 

You will notice that it adds another row under Products, which is not what you are looking for.

 

3. If you try adding new column under Dimensions > Column:

IMAGE

 

You will notice that it just adds the values under each Fruit, which is also not what you need.

 

4. Finally, if you try adding new measure under Measures > Values:

IMAGE

 

You will notice that it splits each Fruit into two sections, which also doesn't meet your needs.

 

5. As you can see, natively adding a custom column in the beginning of the Pivot table, seems to be unsupported for now, so you can submit a feature request [1] to have it as an option.

 

6. However, a work around that might help is to go and edit the first dimension, under Dimensions > Row

7. Instead of having the expression as =[Product], you can add it as =[Product] & ' (Specific Value)'

8. The output is:

IMAGE

 

While it doesn't add an additional column as you want, it does add custom values next to the dimension's values. So it might at least help you achieve the view of the table that you are looking for.

 

I hope that this information was helpful. In case I have misunderstood the use case scenario, please elaborate in details by providing additional information. However, if it has helped you resolve the issue, please mark it as accepted solution to give further visibility to other community members. 

 

---

[1] https://community.qlik.com/t5/Knowledge/How-To-Submit-Feature-Requests-For-Qlik-Products/ta-p/171258...

Help users find answers! Don't forget to mark a solution that worked for you! 🙂