Crosstab with additional column - crystal-reports

My report needs a normal cross-tab section, but with an additional pre-computed column (It's the average of all the non-zero weeks of activity, so a normal cross-tab average will not work). This is a column that is supplied in my dataset.
How can I get it to look like this?

Have you considered adding a SQL Command to your report in the Database Expert?
If you perform the pre-calculations in SQL and pass the results in as a Command table, you can use the calculations like regular table fields. These can be used in a Crosstab like normal fields.

Related

I have Crystal report and need to use results from parameter based on one table to run a parameter on another table

My SQL Table contains RmaNumber, RmaLineNumber and Warehouse, and then a whel lot of other details.
We want to filter (using a parameter) on warehouse to produce a list of RMANumbers and RMALinenumbers to choose from. The problem is that when I include the RmaLineNumbers it makes the dataset to large to display in Crystal Reports.
So I tried splittin the data into 2 tables - the first table contains the Warehouse and RMANumber. The second table contains the RmaNumber and RmaLine Number. The idea is that I put a parameter on the first table to select the warehouse and it returns a list of RMANumbers (a manageable size data set)Then the user will select which RMANumbers they want and from that list I want to filter (parameter) From the second table to see the line numbers (a smaller dataset) then the report will display the details based on the line number chosen. Is what I am trying to do possible in Crystal? is there another way around the issue of the dataset being to large?

Tableau creating a calculated percentage (non-aggregate) based on an aggregated total

Either I am the first person to ever need to display percentages in Tableau or I do not know what to search for! I highly suspect it is the latter...
I believe what I am attempting to ask is how to make a calculated non-aggregated field by dividing by an aggregated number. Although I would prefer just to be able to display the percentages instead of a whole number.
This is how I would do it in Excel:
The data that already exists is Column A and B. In Tableau these would be non-aggregated. What I need to do in Tableau is to generate what is column C (also non-aggregated) because it does not exist in my data. In excel, all I did to get the aggregate number (total) of column B was:
sum(B1:B4)
And for the column C:
=B1/$B$5
But I can't seem to do this at all in Tableau. When I try to use the same syntax, I get an error message: "Cannot mix aggregate and non-aggregate arguments with this function."
Instead of having a calculated field, you can use a Quick Table Calculation on the column.
Right-click the pill of your data > Quick Table Calculation > Percent of Total. This will show the percentages instead. If you want to keep both, just duplicate column b first and then add the table calculation to the new column.

Cognos Crosstab Report Calculated Column Totalling Incorrectly

I have a report in Cognos 10.1.1 that is pulling Profit, Pounds, and Profit/Lbs. Each query has a field 'Measure Unit' that is labeled as 'Spread $', 'Spread Lbs' or 'Spread $/Lb'. It joins these three queries via a union and then loads them into a Crosstab list. The individual queries work correctly, and when dumped into a List Report are fine, but for some reason when in the crosstab report, the calculated profit/lbs column is always wrong. How can I get the calculated column to total correctly in the crosstab?
Three queries pull seperate Measure Units and measures for Profit, Lbs and Profit/Lbs.
The calculation for Profit.
The Calcuation for Profit/Lbs
Properties for the measure fields.
What the report looks like. Middle column should equal Spread $ / Spread Lbs, but does not when in crosstab.
Try to customize Solve Order for your calculations.
Default behavior is Total(Value1/Value2). You need to archive Total(Value1)/Total(Value2)
(Don't change your formulas, just set Solve Order for calculations)

Joining two datasets to create a single tablix in report builder 3

I am attempting to join two datasets in to one tablix for a report. The second dataset requires a personID from the first dataset as its parameter.
If i preview this report only the first dataset is shown. but for my final result what i would like to happen is for each row of a student there is a rowgrouping (?) of that one students modules with their month to month attendance. Can this be done in report builder?
The best practice here is to do the join within one dataset (i.e. joining in SQL)
But in cases that you need data from two separate cubes(SSAS) the only way is the following:
Select the main dataset for the Tablix
Use the lookup function to lookup values from the second dataset like this:
=Lookup(Fields!ProductID.Value, Fields!ID.Value, Fields!Name.Value, "Product")
Note: The granularity of the second dataset must match the first one.
We had a similar issue and that can be resolved this way.
First of All, ensure the first data set's query and second data set's query are working fine by executing separately on the Database client tool such as Datastudio.
Build two data sets on SSRS tool with the respective queries and make sure both the data sets have same key column (personID).
On the SSRS report design, create a table from tool box and add the required columns from the first data set along with the matching key column(personID). Add a new column and use look up function to get the required column from the other data set against the same key column (personID).

Keeping same number of columns at cross tab report

I have a cross-tab report which similar to this
Problem is when there are no data to one month that column won't appear in the report. I would like to keep the same number of column even there are empty values for the row data.
Is it possible to achieve in cross-tab reports??
Thanks
This is a problem more with the underlying dataset. You have two options:
Modify your query to always return data even for "empty" groups
Hardcode the columns into the cross-tab
Option 1 is probably the best approach. Take a look at this similar question: Handling non existent values in sql query expression for ssrs chart