Skip to main content
Announcements
Accelerate Your Success: Fuel your data and AI journey with the right services, delivered by our experts. Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
PAD
Contributor II
Contributor II

Sum quantity on two dimension

screenshot.png

 Hi,

I am trying to sum quantity by name and by year.

But into the graph, each bar contains all the quantity and not just the quantity matching this name.

 

How can I setup my dimensions and mesure ?

I don't find documentation about that.

Labels (2)
1 Solution

Accepted Solutions
RafaelBarrios
Partner - Specialist
Partner - Specialist

now i see the problem.

you need your two table to be connected by just one field, Qlik will do this when fields in two tables has the same name

RafaelBarrios_0-1694100678590.png

 

yo can do this in script by usign an alias in a field

RafaelBarrios_1-1694100770670.png

 

or, if you are using the data manager, by connecting bubbles and selecting the link fields

RafaelBarrios_2-1694101053565.png

RafaelBarrios_3-1694101079504.png

 

hope this helps.

help users find answers! Don't forget to mark a solutions that worked for you & to smash the like button!  

 

View solution in original post

6 Replies
RafaelBarrios
Partner - Specialist
Partner - Specialist

Hi @PAD 

it seems to me that your name field "nom" could be in a table that is separated from the rest of the data model or its not well related.

can you paste your data model?

 

Best,

help users find answers! Don't forget to mark a solutions that worked for you & to smash the like button!  😁

PAD
Contributor II
Contributor II
Author

Hi,

 

thanks for your respond.

 

I have 2 tables (I am just making test with only 2 tables to understand how it works) :

command and partner.

The field nom (name) come from partner, and qte (quantity) come from command.

 

I link them together :

PAD_0-1694099077239.png

 

But into the data model, they don't seems to be link :

PAD_1-1694099129257.png

 

RafaelBarrios
Partner - Specialist
Partner - Specialist

now i see the problem.

you need your two table to be connected by just one field, Qlik will do this when fields in two tables has the same name

RafaelBarrios_0-1694100678590.png

 

yo can do this in script by usign an alias in a field

RafaelBarrios_1-1694100770670.png

 

or, if you are using the data manager, by connecting bubbles and selecting the link fields

RafaelBarrios_2-1694101053565.png

RafaelBarrios_3-1694101079504.png

 

hope this helps.

help users find answers! Don't forget to mark a solutions that worked for you & to smash the like button!  

 

PAD
Contributor II
Contributor II
Author

What if my two tables don't have the same field name (they both have an id field, but i don't want them to link on the id field, I want to match id from partner with partner_id into command)

PAD
Contributor II
Contributor II
Author

Ok, I manage to do it with the data manager.

After creation of the link into the data manager, you have to press the load button in the upper right.

Thanks for your help 🙂

 

RafaelBarrios
Partner - Specialist
Partner - Specialist

then as i paste in the second image

if you are using script

parner_table:
load
id as parner_id,
...
...
...
FROM ....;

 

command_table:
load
parner_id,
...,
...,
...
FROM ....;

 

hope this helps,

help users find answers! Don't forget to mark a solutions that worked for you & to smash the like button!