sum column values
I have a column total revenue which is calculated for each customer on a separate row, but I'm wanting to total alll the total revnue values together for all customers then divide each indivudal revenue by the toal to get a % per customer, is this possible?
thanks
Comments
-
I am thinking one way you could do this is add a column in which you assign a calculation to be the values.
Ex.
SELECT
SUM(Individual Revenues) AS Total RevenueThis would give you a column with total revenue as a number, you could then do one more column in which the calculation would be like
[Individual Revenues] / [Total Revenue] AS Customer%
Aside from column names and a little syntax this should work. Let me know!
0 -
would I do the first calculation on the dataflow?
0 -
basically I need to be able to sum all the values in the total revenue column then be able to divide each on individually into that total
0 -
In that case, yes, you would do the first calculation on the DataFlow. Doing it there will create a new column in general (it will be the same number the whole column).
Once you have this column, you can do a BeastMode calculation on a card to calculate the individual revnue % by each customer. If need be, I can post some screenshots on how to do so, but let me know.
0 -
yes, if you could post a couple screenshots that would be great
thank you
0 -
so I have the totals for each customer group together, I just then need another calculation for all of those totaled together....the attched screenshot shows what we did to get the total revenue for each customer, we then need all of those totaled together to get a grand total of total revenue
0 -
The first part is perfect. This will give us a column we can use for each individual value/calculation.
The next part would be done in the BeastMode section of the card analyzer. You would add a new calculation to give you the % of revenue by each customer. After this, the calculation will show up as a datapoints on the left hand side which you are able to add to the table. I attached some screenshots to help show which locations I am talking about.
Let me know if this works for you!
0 -
how do I calculate the CustomerTotalRevenue?
0 -
That is the number you just calculated on the dataset with the ETL process.
0 -
so my calculation, Total Revenue is calculiating the total revenue for each customer, but how do I total all the total revnue amounts up after that?
0 -
If you want total revenue (not per customer) you need a new column that takes a sum of all of the revenues and sums them together for one value for the entire column. You can use this against the individual revenues. I feel I am starting to repeat myself now so there is not much more help I can offer. Best of luck.
0 -
yeah, that is what I'm trying to do is get a sum of that column of customer revenues so that I can get my percentage of revenue for each customer
TotalRevenue/Sum of All Total Revenue's
thanks
0 -
I just came across a way that should be able to solve your problem.
Instead of creating the dataflow with the ETL feature, use the SQL feature.
Once here, you will choose the same dataset as the input dataset. However, for one of the transforms you will sum the profit column. I attached an image to show what this might look like. From here, you should have a column with the same total revenue number for all companies which you can then use to figure specific %.
Hopefully that helps!
0 -
how do you write the Output_dataset?
thanks
0
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.6K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 9 Federated
- 2.9K Transform
- 102 SQL DataFlows
- 626 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 753 Beast Mode
- 61 App Studio
- 41 Variables
- 692 Automate
- 177 Apps
- 456 APIs & Domo Developer
- 49 Workflows
- 10 DomoAI
- 38 Predict
- 16 Jupyter Workspaces
- 22 R & Python Tiles
- 398 Distribute
- 115 Domo Everywhere
- 276 Scheduled Reports
- 7 Software Integrations
- 130 Manage
- 127 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 11 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 110 Community Announcements
- 4.8K Archive