compute a division using list summary field in cognos report studio - division

I have a Cognos Report created by a List. I used the Total function the report has to create a row of Totals, i.e. Total [TodayOrderCount] and Total [#ShipmentDaysOrder].
I then need to compute a division: Total [#ShipmentDaysOrder]/Total [TodayOrderCount]. For instance: 1,687/50=33.74
But instead the report shows 36.84 or any other number.
Does someone have experience with this?

Related

Computing XNPV in Power BI based on specific starting date?

I am trying to compute the NPV "Net Present Value" of a series of cash flows in PowerBI, using the XNPV formula, but want to be able to specify at which date the calculation should start.
I have 1 data table with 2 columns, "Month Ending", and "Value". The "Month Ending" column contains dates using the "Date" datatype, that are monthly for 40 years (following month end convention, I.E., 12/31/2022, 1/31/2023, 2/28/2023 etc...). The second column contains numbers of the data type "Fixed Decimal", representing the cash flow expected to occur in each monthly period. Additionally, I have a "What-If" parameter, of the "Decimal" data type, that can take a value between 0 and 1.
What I am able to do currently is compute the NPV of the entire cash flow series using the "XNPV" formula. What I want to be able to do is specify the exact starting point that the XNPV calculation should begin at.
Suppose we could create a parameter "Sale Date", that is is say 12/31/2024. I want a formula that would tell me what the XNPV is on 12/31/2024, using all cash flows that occur after 12/31/2024.
Ideally, I should be able to control this date using a slicer, and add it to a card on my display. The goal is to have the user drag a slider for the "Sale Date", and to see the value update on the card visual in real time. The end user should not have to modify any DAX expressions or Power Queries to change the result.
I have been struggling with this issue for a while, and cannot find any solutions that are dynamic in the way that I have described. Is what I am asking for even possible in PowerBI?
Thanks!

How to build an expression in a total row in MS Access

In MS Access I need to build an expression in the total row of a table and I don't know how to do it.
for example the 2nd column of this table says whether the 1st column is positive or negative
Number ......... Sign
10...............pos
-5...............neg
20...............pos
-15..............neg
now in total row the 1st column is sum and the 2nd is the sign of the sum
10...............pos
I have searched the net and my training resources but I couldn't find a clue
I would be glad if someone help me

How to get a subquery total in SSRS

I'm new to SSRS because I'm needing to do some more complex reports that are getting increasingly difficult/impossible in Crystal Reports. The initial report I'm working on involves getting a Trailing-Three-Month total for sales by salesperson grouped by week. Given a date range and a selected salesperson, I can get the basic report done with total sales grouped by year and week number (1-52).
However, for each of those weeks, I need to get the total sales for the 13-week period ending with that week. For example, for week # 20 - I need to show the total sales for weeks 8-20. On week # 21, I need to show the total sales for weeks 9-21. Etc.
I've managed to do some date formulas to calculate the starting & ending dates of the three month period. But what is the preferred way to get the subtotal of sales into the main report? In Crystal Reports, there was a way to pass a value from a subreport into the main report. But from what I understand, you can't do that in SSRS - subreports are "display only". Eventually, I will need to graph the TTM amount.
I've tried several methods, but I want to know what the best way is to get these kind of values? If I were writing code, it would just be nesting Do-While loops. What is the best method as far as complexity and/or performance?

Creating calculated items in powerpivot

I am trying to create a new row of data like the following:
Line item. Actuals
Total compensation 200
Net revenue 400
Net rev per total comp. 2
I used to be able to do a calculated item to do this in old pivot table but how do I accomplish in powerpivot? It needs to be a row calc not a column
If you are using a ssas cube then it is possible using the calculated member option where you can drag and drop line items (members) and divide which is pretty easy
Just connect to SSAS and Query --> Design in the upper menu you can find a calculator, clicking that you can achieve.
can you just elaborate on database used and excel version

How do I automate a report on variance in the same SQL table fields on monthly basis?

I have a T-SQL view with integer fields. I need a report on a monthly basis regarding the difference from one month to the next, i.e. so many people were engaged in a particular activity on 8am of the 1st of this month, so many the previous month, here is the difference. The numbers fluctuate all the time. I need a variance between 2 snapshots in time.
I am using the SSRS, however in reporting services I can only display the "current" situation. I could run a report at 8am of the 1st of each month and then calculate the differences manually. But how could I automate this calculation and then report on the difference?
I have tried to import data from SQL to 1 Excel spreadsheet from 1 month, then to the 2nd spreadsheet from the 2nd month. The 3rd spreadsheet calculates the difference. But how do I create a nice looking report from Excel?
Additionally I cannot send the report by email. It has to be available online.
Furthermore, each office wants their figures to be confidential and not visible to another office.
Thanx in advance.
Can you add a UserCount table that stores each office's user count for each month? It could have columns like:
id
date
user_count
office_id
You would insert a new row each month based on what the view tells you that month for each office. Then it's as simple as exporting that table to Excel and graphing it using Excel's built-in graphing tools.