I am looking for a solution to sort an Excel pivot table by multiple columns. My pivot table looks like this:
The original data is laid out in the format below, where columns D and E are helper columns (and usually hidden). Column D is always 1, and column E is populated based on the input in the Accomplished column (column C).
In the pivot table, the % Done column is a calculated field that divides Done by Days.
I would like to sort the pivot table first by % Done in descending order (as shown in the picture), but then also by Total Days in descending order, and then by Participant Number in ascending order.
It seems like this should be relatively simple, but I can't seem to figure it out. Any help would be appreciated.
Related
I have a pivot table with employees names, their grand totals of cases worked for the month, the days they worked during the month, and the case counts for each day.
I have them all stacked on top of each other on a sheet for fast viewing.
I created a column to countif Column (A) has a partial text value that matches the month.
In that column (AR) it returns 1 for true and 0 for not true.
I'm trying to create a formula where it sums up the 1s between the 0s.
The picture is horrible due to the size limits.
Basically, I need to count the days the employee worked and find the average case count for the month for each employee.
I can't use the average function in the pivot table because the count is based on IDs.
I tried If statements, and SumIfs.
ATTACHED IS A SAMPLE OF THE FILE I'M WORKING WITH
Picture of the Spreadsheet as requested
Sorry, i'm working on Excel in french. But I hope my answer with the file modified will help u understand what I'm talking about.
Here is your Excel sample with my modifications : Your Excel file that I modified
You can create another pivot table, that uses your previous pivot table as new datasource. But before doing that, make sure the elements of your first column "Claimed by" is repeated, by checking the column option "repeat element labels" like this :
In this new crosstab, you add as columns : the sum of "Case Count" ; and the count of "Days".
After that, you can filter the column "Claimed by" by selecting only elements without the word "total".
Then your average will be obtained simply by dividing the two columns.
Why pivot table does not show identical rows from the initial table? My expectation is that the pivot table could show these in separate rows.
The initial table has 100 rows and my pivot table (while taking 4 columns) showing less.
To be more specific: All cells in 3 columns out of 4 are formatted as text, 1 column as number. If there are two rows which are identical in all 4 columns why only one of these is shown in the end pivot table? The number column is not summarized.
Identical values in the rows of a pivot table will be rolled up into one row. If the number is in the values area of the pivot table, it will be summarized.
See this data example:
If the number column is in the Values of the pivot table, then the data gets summarised and only three rows of text are showing. It is entirely possible to rename the column title from "Sum of ..." to something else, so it may not be apparent that the data is summarised.
If you want to show all data, then put the number column into the rows area. You can then format the pivot table to repeat all item labels if you want to see the text for all rows.
Edit: If all values in the Rows area identical, then the data will be rolled up, too. A pivot table is about summarizing data. You'd typically have something in the values area that calculates something about this unique combination of four values.
If you want to show all duplicates, you need to enter a unique 5th column in the row area.
I would like to present some data in Excel in a table. I have a sheet with three columns: date, time_spent and user_id. Every row is a data record. I want a table with a column for every date and every value with time spent below the date.
Using the transpose function under paste special I get this:
However I would like only one column per unique date, so the amount of columns decrease like this:
Does someone know how to do this?\
I have more than 10000 rows, so manually is too much effort...
Using Pivot Tables as Tim Biegeleisen suggested I cannot get what I want either, I'm not an expierenced user of Pivot Tables so probably I'm doing something wrong:
Excel file as shown in above picture
Here is one way of using a Pivot Table as suggested by Tim above in the comments, but you must use it on your original, non-transposed data: (and note which parameters go to which areas.
A disadvantage of the Pivot table is that the column headers are text strings and not dates. If your version of Excel is 2010+, you can use Power Pivot or Get and Transform to do a better job:
Open the Query Editor, change the format of the Date column, and Pivot the column:
Then Save the results:
Advanced filter dates to unique values in a new column
Copy and transpose them to make your column titles
Insert a new column B with the formula =TEXT(A2,"yyyyddmmm")&COUNTIF($A$2:A2,A2) and fill down
Below your new column headers put in the formula =IFERROR(VLOOKUP(TEXT(H$1,"yyyyddmmm")&ROW()-1,$B$2:$C$8,2,FALSE),"") and fill down and across. You will need to fill it down to cover the maximum number of instances of each date.
Adding a sumif to this table and your initial table would be a good way to check you got everything.
Is it possible when pivoting a series of data to calculate the difference between 2 columns when 1 column is your column filter? for example, I'm trying to compare 2 accounts receivable reports a week apart, so I inserted a manual column in both reports called "week" and then, before pivoting, I consolidated the 2 reports. Now I have 1 column called "week" with 2 different values. When I pivot, I want to put the "week" column in the Column Filter and I want to put the outstanding balance in values, and I then I need to calculate the difference between the weeks. I can't seem to find a way to do this.
Thanks,
Assuming you are using MS Excel ...
From your description, I believe you have a raw data table that looks like this ...
... and a PivotTable that looks like this ...
If you were looking to calculate the difference between Account1 and Account2 on a weekly basis, this would be straight forward, using a calculated field. However, in order to calculate the change in Account 1 week over week, and the change in Account 2 week over week, you will need to go back to the raw data table and perform the calculation there, in new columns.
In the raw data, Column A is Week, Column B is Account1, and Column C is Account2 ...
Make header in Column D Acc1WkChng and the header in Column E Acc2WkChng
The first row of each of these columns is 0. The second row of Acc1WkChng is =B3-B2. The second row of Acc2WkChng is =C3-C2
The raw data table now looks like this ...
On the PivotTable, pick the PivotTable Tools -> Analyze Ribbon. Choose Change Data Source and increase the selected range to include Columns D and E.
Add Acc1WkChng and Acc2WkChng to the Values area. Format accordingly.
The PivotTable now looks like this ...
Note: This pivot table is merely a transpose of the original data. Presumably, you want to do something more interesting with it.
I have some data in an Excel sheet, like this:
Now I want to get below result with Pivot tables:
As you can see I want to put the columns name's of the source data at the first columns of the pivot table and sum of each columns in the second one.
Any help highly appreciated.
Insert a new ColumnA, follow the process here, select output Table Columns B and C and pivot those. Relabel to suit.