Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I'm sorry for my approximate English.
I use a set analysis to calculate how many sales each seller made, and also how many sales in the shops.
seller_name | Count({[Date de vente]=p(Date),item_type_name={'tasse'},detail_id ) |
Alfred | 12 |
Robbyn | 17 |
Those to sellers works in the same shop "FRINGS"
shop_name | Count({[Date de vente]=p(Date),item_type_name={'tasse'},detail_id ) |
FRINGS | 29 |
ENARGE | 45 |
in a pivot table or table, I want to assign to the seller all the sales of the shop, ignoring the dimension "seller_name" in the line of the seller_name
Like this when i choose the shop : FRINGS
seller_name | |
Alfred | 29 |
Robbyn | 29 |
I have the dimension "shop_name" for the shops et and "seller_name" for the seller
Thank you
First, I don't believe your count formula post here works since the Set Expression seems missing closing ">}" .
If your working count formula looks like below,
Count({<[Date de vente]=p(Date),item_type_name={'tasse'}>} detail_id)
Then, you can try:
if(GetCurrentSelections([shop_name])>0
, //adding RED highlight to your working formula
Count(Total distinct {<[seller_name]=,[Date de vente]=p(Date),item_type_name={'tasse'}>} detail_id)
, //you original count formula
Count({<[Date de vente]=p(Date),item_type_name={'tasse'}>} detail_id)
)
Above solution is based on my understanding of your requirement of in two cases,
1) If any selection of shop_name, use all shop sale count for each seller in this shop
2) If no shop selected, mark seller true sale count
First, I don't believe your count formula post here works since the Set Expression seems missing closing ">}" .
If your working count formula looks like below,
Count({<[Date de vente]=p(Date),item_type_name={'tasse'}>} detail_id)
Then, you can try:
if(GetCurrentSelections([shop_name])>0
, //adding RED highlight to your working formula
Count(Total distinct {<[seller_name]=,[Date de vente]=p(Date),item_type_name={'tasse'}>} detail_id)
, //you original count formula
Count({<[Date de vente]=p(Date),item_type_name={'tasse'}>} detail_id)
)
Above solution is based on my understanding of your requirement of in two cases,
1) If any selection of shop_name, use all shop sale count for each seller in this shop
2) If no shop selected, mark seller true sale count
Thank you , it works.
Hi, I have a new problem now.
i've tried with one shop it's ok, but when i select more than one i have the same result for all the shops.