Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
pkelly
Specialist
Specialist

Pivot Table - Keep Column Position

Hi All,

Been working on a dynamic Pivot Table where the user can select the dimensions / values that they are looking to see from a list box...

Got some great ideas from an example QlikView app that was previously posted - have included this with this discussion...

Have hit an issue which I am trying to resolve...

Screenshot 1.jpg shows the layout that I want to keep - note DateDelivery is going along the top row / 2 expressions being displayed...

Screenshot 2.jpg shows the layout after I have deselected one of the expressions i.e. am only showing 1 expression - note DateDelivery is now displaying as a normal column.

If I select another expression to display, DateDelivery moves back to the top row...

Is there anything that I can do that can force DateDelivery back to the top row regardless of how many Dimensions / Expressions have been selected?

Thanks

Paul

11 Replies
hopkinsc
Partner - Specialist III
Partner - Specialist III

can you post an example of the issue you are experiencing?

Not applicable

Are you using calculated dimension like the sample? I think that's where the issue is. If you are, then just use DateDelivery as your second dimension, and Drag that column up your Pivot for a horizontal presentation..

pkelly
Specialist
Specialist
Author

Hi... Example is attached (Forum Example.qvw)...

If you click on the Measures list and select two measures you will see DateDelivery along the top but when you deselect one of the measures it moves to the column...

pkelly
Specialist
Specialist
Author

Hi Patrick

Tried this in my live example...

Have three measures (Sales, GP and GM%) in this and have all three selected in the list box.

Added the Dates as dimension and moved to the horizontal row.

Deselected GP and GM% and the Date moves from horizontal to vertical.

Regards

Paul

Not applicable

Hi Paul,

If your unable to attach a sample, kindly list your dimensions and expressions so we can better understand.. thanks!

pkelly
Specialist
Specialist
Author

I actually have two versions of this app - I started with non calculated dimensions and used the "Enable Conditional" option e.g. =varViewDivision = 'Yes'

varViewDivision is a variable and I toggle the value of this via a button between yes and No.

Have done the same with the expression on this version.

I still have the same issue - as soon as I get down to one expression being displayed, my date column moves from horizontal to vertical.

If I move the date back to horizontal and selected a second expression to display, the expressions then move to horizontal.

Is there any way that I control where these are displayed via code?

Not applicable

Hi Paul,

I am not getting the same results as you are. (See attached)

Clipboard02.jpg

What version are you using? Im on 11.2

pkelly
Specialist
Specialist
Author

Thanks Patrick

I have created a version with dummy data (albeit very little)...

If you click on the "Gross Profit" Button (the text should turn to white), you will be left with only Sales as a visible expression - note that month moves from horizontal to vertical.

Am on same version as you...

Regards

Paul

Anonymous
Not applicable

I'm having the same issue. Did you ever get a resolution?