Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to set sum of a column as the value of a column

I am making a pivottable. I have diffrent types of articles as rows. Som of the articles are specially marked in [no1] as 1.

I have made a column that shows how many of my special products i have sold. Now - i want to make a column that shows total of sold special products - regardless of product number. In the example below, that column will show 7072 in each single cell.

Is that possible? I have tried a litte bit of stacked aggregation, but with no luck so far.

Please help me!

2017-05-28 18-24-26.png

11 Replies
gladi-cz
Creator
Creator

Hello Felix,

put this expresion Aggr(sum( {<[no1]={1}>} count),Group) as Dimension to your table.

Group is dummy diminension define in the script, which aggr all of records to one group:

Load

*,

'All'              as Group

From ABC

My test table:

Capture.JPG

If you have .qvf of my example, please let me know.

BR,

Petr

ahaahaaha
Partner - Master
Partner - Master

Hi Felix,

Can you append QVF with a piece of your data?

Regards,

Andrey

Anonymous
Not applicable
Author

Thank you so much for your time!

Unfortunatly, i dont get it yet.

I dont really understand how the i add the piece of code as dimension. Am I supposed to add it in data import?

Please, see attached .qvf.

I want the measure Aggr(sum({Sale={Yes}>}Count),Group) to show 61 for A, 16 for B and 25 for C, in the whole columns.           

Anonymous
Not applicable
Author

Thank you so much! I have added a .qvf in the post above.

Anonymous
Not applicable
Author

Anyone?

gladi-cz
Creator
Creator

Sorry for delay.

What about this solution? Capture.JPG

Put following expresion as column:

Aggr(sum( {< Sale = {'Yes'} >} Count),Customer)

P

gladi-cz
Creator
Creator

Add Qvf.Přílohy

jonathandienst
Partner - Champion III
Partner - Champion III

Assuming the value 1 or 0 in [no1]:

Sum({<[no1] = {1}>} [no1])

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Anonymous
Not applicable
Author

Thank you so much for your help.

If i move our new formula to be used as a measure, i will get this result. 2017-06-02 09-56-05.png

Are there any way for me to get this result?

new.png

I want to relate number of sold products of a specific product to the total number of products sold on sale.