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: 
QlikFTW
Contributor
Contributor

Need to group columns and have the same name for them

Hey Everyone,

I have a table I'm recreating from Excel and the client would like the columns related to each other grouped together and named.  They designed it in Excel and I'm converting it over.  I can organize the columns in the order they want, but I can't seem to find a way to include the group name like I would in Excel (Missing Merge and center).  I've simplified this in my example below:

QlikFTW_0-1629844113368.png

Currently I'm making the group names all say Running Group Goal, Running Group Performance, ect, ect.  That is very wordy and takes up too much space on the page.  

I've thought about including a Text box with the group titles I need, but I'm worried about it not matching the columns correctly. 

Thanks,

2 Replies
anthonyj
Creator III
Creator III

Hi,

This is going to be dependent on your data model but it looks like you're creating a pivot table with a two level hierarchy in the groups. For example: Your data model would have a group column that contains your header values. Each group would have iterations of Goal/Performance/Sample Size. And then you'd have a count or sum for the values in your rows.

To use the pivot table the rows are going to have to mean something as well. What is the context behind each row of this data. Is there a date that these values were collected that you can use to separate them?

For example along with each group and category pairing there's a date that goes with that value.

I've recreated your code to create a pivot table that looks like this:

anthonyj_0-1629847868513.png

Here's a sample code I used based on your screen shots to give some context behind the structure:

data:
load * Inline [
Group Category Date count
Running Group Goal 1/07/2021 7
Running Group Performance 1/07/2021 6
Running Group Sample Size 1/07/2021 10
Running Group Goal 1/08/2021 7
Running Group Performance 1/08/2021 6.5
Running Group Sample Size 1/08/2021 15
Running Group Goal 1/09/2021 7
Running Group Performance 1/09/2021 7
Running Group Sample Size 1/09/2021 12
Running Group Goal 1/10/2021 7
Running Group Performance 1/10/2021 8
Running Group Sample Size 1/10/2021 13
Walking Group Goal 1/07/2021 15
Walking Group Performance 1/07/2021 14
Walking Group Sample Size 1/07/2021 10
Walking Group Goal 1/08/2021 15
Walking Group Performance 1/08/2021 15.5
Walking Group Sample Size 1/08/2021 15
Walking Group Goal 1/09/2021 15
Walking Group Performance 1/09/2021 16
Walking Group Sample Size 1/09/2021 12
Walking Group Goal 1/10/2021 15
Walking Group Performance 1/10/2021 13
Walking Group Sample Size 1/10/2021 13
Jogging Group Goal 1/07/2021 10
Jogging Group Performance 1/07/2021 9
Jogging Group Sample Size 1/07/2021 10
Jogging Group Goal 1/08/2021 10
Jogging Group Performance 1/08/2021 9.5
Jogging Group Sample Size 1/08/2021 15
Jogging Group Goal 1/09/2021 10
Jogging Group Performance 1/09/2021 10.5
Jogging Group Sample Size 1/09/2021 12
Jogging Group Goal 1/10/2021 10
Jogging Group Performance 1/10/2021 11
Jogging Group Sample Size 1/10/2021 13
Belly Crawl Group Goal 1/07/2021 30
Belly Crawl Group Performance 1/07/2021 28
Belly Crawl Group Sample Size 1/07/2021 10
Belly Crawl Group Goal 1/08/2021 30
Belly Crawl Group Performance 1/08/2021 29
Belly Crawl Group Sample Size 1/08/2021 15
Belly Crawl Group Goal 1/09/2021 30
Belly Crawl Group Performance 1/09/2021 31
Belly Crawl Group Sample Size 1/09/2021 12
Belly Crawl Group Goal 1/10/2021 30
Belly Crawl Group Performance 1/10/2021 32
Belly Crawl Group Sample Size 1/10/2021 13

](delimiter is '\t');

This going to be dependent on your data model as to how you can display your data.

Regards

Anthony

QlikFTW
Contributor
Contributor
Author

AnthonyJ,

 

Thanks for your response.  You were right the way to do this is with a Pivot Table with Group Column name included in the consideration. 

I think I got it.

Thanks.