How to create a grand total as a variable in Tableau or divide the (top 10 grand total by columns of each category) / (total of each category ) - set

I have a question, It would great if someone can help me in this.
I am currently working on this data where I am creating a view of top 10 customers by sales and showing their grand totals. I am able to do it but now I want to get % of total i.e. (grand total of top 10 customers by sales)/ (Total Sales)
so in this picture as you see I want to divide (Grand total of each category)/(Total Sales of each category) but i am not able to figure out the solution or a logic to do this. Any help would be appreciated.

Related

Magento 2 same product with multiple product costs prices

I have an issue right now and I believe many people might have this issue I am wondering if someone has found a work around so my issue is I have products that I buy stock for on a daily basis due to excahnge rate and other things the same product sometimes costs me different every time so my issue is,
If I have a Samsung watch I have 5 units in stock that cost me £35 Then I see a good deal on them and buy another 10 units these cost me £30 but I still have the 5 units in stock that cost me £35 so how can I upload/update the 10 units making 15 units in total but have a seperate cost price for the 10 units compared to the 5 units as I need this for reporting profit and loss reports.
So Ideally I want to be able to update my stock qty each time I do so I need to set a new cost price for that same product for selected amount of qtys,
Right now I am currently making the same product/SKU Multiple times because the product is the same but has cost me multiple by prices and I do not want to not have it listed for sale until the other stock sells and I do not want to keep making multiple products as customers think the products are different..
Any help will be strongly appriciated!
Have you check Tire Price concept in magento ?
I think this will full fill your requirement.
Let me know if you have any query.

How to recalculate the percentages from total when filtering in Power BI?

As I am not really sure how to express myself, I'll better demonstrate what I need to be done.
This is a sample DB.
You see here
that we have a category slicer and on the table is show the percentage of sales for a given product and its description.
On the next photo I used the slicer to filter the products on the "16GB" category. My task is when filtering, the total of the % to show 100% and the distinct products to show the percentage of this total (as part of the category, not of all other products and categories).
Thank you in advance!
You need to have a raw amount in your dataset. I was able to do this using this sample data.
Then for both table visuals in Power BI, you should select show value as percent of grand total for the amount value. This will allow Power BI to calculate the percentages dynamically as the filter criteria from the slicer changes.
Here is the result.

How to express my products in lower hierarchy as a % of total sales in PowerBi Dax

Hi I have issues trying to express my products in the lower hierarchy as a % of total sales in my report. Example as below in the form of a table in Power Bi:
Category
Drinks Total $100k
Sub Category
Soft Drinks $50k - 50% of total
Teas $50k - 50% of total
Brand
Coke $20k (How to show this as 20% OF TOTAL DRINKS instead of 40% of Soft Drinks)
Pepsi $10k
7-UP $10k
Just calculate sales on a specific level by manipulating FILTER inside CALCULATE.
Here is an example:
%ofCategory = CALCULATE( DIVIDE(SUM('fact'[Val]), CALCULATE(SUM('fact'[Val]), ALL('fact'),'fact'[Category] = SELECTEDVALUE('fact'[Category]))))
Revenue per Drinks type Mix (%)
My Dax formula is this
Revenue per Drinks Type Mix =
IF(ISFILTERED(Sheet1[Drinks Type]),
DIVIDE(SUM(Sheet1[Revenue]),calculate(sum(Sheet1[Revenue]),ALLSELECTED(Sheet1[Revenue],Sheet1[Drinks Type]))),
DIVIDE(SUM(Sheet1[Revenue]),CALCULATE(SUM(Sheet1[Revenue]),allselected(Sheet1[Revenue],Sheet1[Drinks Name]))))
Not sure why the [Drinks Name] showing 100% instead of the % of the Total [Drinks Type]
But ultimately, i would like to express the [Drinks Name] as a % of Total Revenue.
Please pardon me for the mistakes i may have made. Still a newbie here with Dax.

SSRS Bring Total in to Matrix/Tablix

In the image below I need to calculate the two blank columns 'Percentage Total Pend' and 'Percentage Total NMI'. I need to divide the first column number by the total.
Ex: 1,326/4,491
I have researched how to get the Total value of the group inside and came across 'Inscope' but didn't fully understand the functionality. From what I have gathered this issue is because the Total or Subtotal is outside the grouping or Tablix. Any help would be greatly appreciated
enter image description here

Magento: Minimal quantity different sizes

I'm making a shop with clothing. But there is a minimal order amount per order. Now i want to have a choice that the customer can make with different sizes.
So the minimal count is 10 pieces, and if a customer wants 4 size M, 5 size L and 1 size XL. what is the easiest way in code that i can accomplish this?
I'm using simple products associated with configurable products.
Maybe this could help :)
How to get the Total Quantity Of All the Items In your Shopping Cart

Resources