- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can't combine rows
Hello,
I am new to Qlikview and developing a dashboard. I am working on a Pivot table that gives details to users based on type of service provided. Currently I have this:
As you can see it works well but I need to be able to display all similar services as a single row with total number of units. This means that the 5th entry in the example above should simply be one row with a total of 131 Units. Units is a column read from a database and the 3 entries come from the fact the user has placed 3 orders each with a different number of units so there are 3 rows. I have tried changing the column to be a calculated dimension "sum(Units)" but my table then looks like below:
I have looked online and found an option to use the aggr function to perform a 'group by' but I am not having success. I have tried "=If(Service = 'SAN GB', Aggr(sum(Units),Units),Units)". This however gives wrong values and "=If(Service = 'SAN GB', Aggr(sum(Units),UnitPrice),Units)" gives the below results:
*I added the if statement since there are other values in the column "Service" but they are not causing issues.
I don't know how best to get the results I need. Any help or a nudge in the right direction will be appreciated.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Remove UnitPrice from dimension and use expression like =Sum(UnitPrice)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the help. The issue with this is that there are more columns after Units that detail when the services were ordered:
If I was to make the Units an expression instead of a dimension wouldn't it mess up the rest of the table? If possible a calculated dimension would work best for my needs from what I have read.
*Sorry for not clarifying this earlier
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That is why it is always recommended to share your sample qvw, otherwise, the thread length keeps growing with such unwanted misunderstanding issues. Preparing examples for Upload - Reduction and D... | Qlik Community