sort by sum of a field

I have a table with several thousand records with the following fields:

username, job, total pages

What I want to do is group the records by username, then count the total of 
all grouped records of the total pages field to get a sum.  Then I need to 
sort the results of the total of the "total pages field in decending order. 
I got a report to show me the summary of the user name and jobs, and to show 
the total from the totalpages, but how do you sort the report on the total 
pages by decending order?

Darrell Eddy 


0
Darrell
4/14/2010 4:22:50 PM
access.reports 4434 articles. 0 followers. Follow

1 Replies
1457 Views

Similar Articles

[PageSpeed] 24

Use the report Sorting and Grouping.

-- 
Build a little, test a little.


"Darrell Eddy" wrote:

> I have a table with several thousand records with the following fields:
> 
> username, job, total pages
> 
> What I want to do is group the records by username, then count the total of 
> all grouped records of the total pages field to get a sum.  Then I need to 
> sort the results of the total of the "total pages field in decending order. 
> I got a report to show me the summary of the user name and jobs, and to show 
> the total from the totalpages, but how do you sort the report on the total 
> pages by decending order?
> 
> Darrell Eddy 
> 
> 
> .
> 
0
Utf
4/14/2010 6:20:01 PM
Reply:

Similar Artilces:

Pivot Table
Hi My data in table are very simply organised as below: --------------------------------------------- Res.no City Code Var1 Var2 Var3 --------------------------------------------- 1 City1 CD0001 num num num 2 City1 CD0002 num num num 3 City1 CD0003 num num num 4 City1 CD0004 num num num 5 City1 CD0005 num num num 6 City2 CD0006 num num num 7 City2 CD0007 num num num 8 City2 CD0008 num num num 9 City2 CD0009 num num num 10 City3 CD0010 num num num 11 City4 CD0011 num num num 12 City3 CD0012 num num num 13 City3 CD0013 num num num 14 City3 CD0014 num num num 15 City1 CD0015 num nu...

moving sum
Hi, I have a list of monthly payments, and I want to create a column that sums those at the end of each year, six months or a quarter . EX: 1 0 1 0 2 4 4 0 1 0 1 6 .... What formula should I use in the second column to have a sum at every 12th,6th or 3rd row? Thanks. Neda Assume your data begins in A1. In B3 use: =SUM(A1:A3) Select B1:B3, grab the fill handle, and fill down. This will sum every 3 rows. For every six rows, in B6 use: =SUM(A1:A6) Select B1:B6 and fill down. Same process for every 12 rows. HTH Jason Atlanta, GA >-----Original Message----- >Hi, >I hav...

Linking Outlook fields from the "Contact Folder" to a custom form in Outlook...
Using Exchange Server 2003/Outlook 2003, we have created a custom Help Desk form in Outlook. We would like the ability to link specific fields from the Contacts Folder (Example B), in a drop-down list box if possible. We are far from knowing that something like this is even possible. Would appreciate *any* suggestions. Thank you. ...

Outlook 2002 Contact Phone Number Field Formatting
Why don't phone numbers entered in the phone number contact fields on Outlook 2002 automatically format to include the paren's and hyphens? If this is suppose to happen, what is the setting to make it happen? They do here and always have. What are you seeing? --� Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. After searching google.groups.com and finding no answer mike <michael.kelner@fmr.com> asked: | Why don't phone numbers entered in the phone number | contact fields on Outlook 2002 automatically format to | include th...

Where's the Sort by New Message option?
Not sure when the layout of the newsgroups changed but I can't seem to find the ability to sort by new message in a thread instead of sorting by just the original thread date. That was hugely helpful as I could follow along and see what threads were still active. If you're gonna hang around in the newsgroups (any newsgroups), you may want to start using a newsreader. Microsoft Outlook Express can do it for you. Saved from a previous post: You may want to connect to the ms newsserver directly: If you have Outlook Express installed, try clicking on these links (or copy and paste i...

How to sort account list?
I'm using MS Money 2004 Small Business. In the account list, my accounts are catagorized by and in this order: - bank accounts - credit accounts - investment accounts - loans and liabilities - asset accounts TOTAL BALANCE In the above view, I cannot easily determine totals for assets and liabilities. The following view does this. - bank accounts - investment accounts - asset accounts SUBTOTAL -loans and liabilities SUBTOTAL TOTAL BALANCE How do I get the above view? Thanks, Brett I don't use Small Business. But you can run a Net Worth report to get total assets and ...

Sorting
Hi, is it possible to use variable for sorting? Something like: declare @sort varchar(10) SET @sort='column1 DESC' SELECT ROW_NUMBER() OVER (ORDER BY @sort)AS rowId, * FROM table Is dynamic SQL only option? Thank you, Simon On 15/04/2010 11:28, simon wrote: > Hi, > > is it possible to use variable for sorting? > > Something like: > > declare @sort varchar(10) > SET @sort='column1 DESC' > > SELECT ROW_NUMBER() OVER (ORDER BY @sort)AS rowId, * FROM table > > Is dynamic SQL only option? You can use CASE to he...

Row names will not move with sort
Each row in my summary table in Sheet1 is hyperlinked to a corresponding table in Sheet2 with additional details. I need to move the rows in my summary table (Sheet1) and preserve the links to and from the details tables (Sheet2). I found that I can move rows in Sheet1 with cut & insert and the hyperlinks are maintained. I can travel from a row in summary table (Sheet1) to details table (Sheet2) and back, even after the corresponding row (Sheet1) was moved. But if I sort the rows in Sheet1 the links from Sheet2 back to corresponding rows in Sheet1 lead to presorted locations. Apparen...

show continous fields
I would like a control (or subform) on a form to behave similar to a report field set to "can grow" and "can shrink". I want to view several records continously, not broken up like the continuous forms requires, but more like a report that shows the data continuously. I tried putting report on a form like a subform, but MS Access doesn't go for that. Is there any way to accomplish this? In this setting the data is for viewing only. -- sam Yo can use the form record source to remove the records that you don't want to display, if Null or Empty? Why do you need...

Secondary lookup field in CRM 4.0
Hello all. I have a question regarding secondary lookup field within the form of the Opportunity entity on CRM 4.0 (upgraded from 3.0). To be able to display a secondary lookup (pointed to contacts), I have used a JScript (as well as two new attributes) on the form's onLoad event (pasted below). It worked fine on CRM 3.0 but after the upgrade to 4.0, the form doesn't report any JScript error but no lookup field is displayed - only the lookup icon is there and it doesn't respond to clicking. I haven't been able to find what parts of the JScript should be changed in order...

Calculate sum of product in Excel 2003
Hi Guys, Sorry to bother you. I just couldn't find a way to solve it. Here is the scenario, A B 1 2 3 2 2 4 3 4 3 4 5 4 I need to find the sum of product in the column A and B. I can do this by using a third column. I simply find the products then sum them. I need to do this in one formula, not another column. I can do this by =a1*b1+a2*b2+....... The problem is the columns have over 50 values. Manually writing that would be real cumbersome. Any suggestion? Mosaddeq One of the few times that this is be...

sorts not sorting
OK- Thanks to everyones help I now i have a list i can work with... but there are a few problems.... the zips are all 5 digit and now i have to sort them... the problem is, THEY WONT SORT CORRECTLY!!!!!!! The numbers are not in order... some are but a lot are not... is there anyway to fix this???? i need to sort them by zip code but cant seem to get them to do it correctly.. any ideas??? ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ You are going to be far better of...

Exporting fields in CRM 4.0 Knowledgebase
I'm attempting to export some of the fields in the CRM 4.0 knowledgebase, and most of them are easy enough to do, as they are non-joined fields. However, the "Body" of the KB I'm a little unsure about. I see int he SQL table/view, there is an "articlexml" field and a "content" field. I'm unsure on how to hand the export of these two fields, or if I can disregard one of the fields. Does anyone have any ideas for handling this type of content? -- Sketchy ...

import- number- sort?
I imported this data into a spread sheet- I tried to format it to number, but when I sort it- I get : 37.08 4.33 4.79 4.8 42.56 5.94 Whats up with this? Thanks Brent Hi Brent, Install the TrimAll macro, select the column and invoke the macro from Alt+F8 http://www.mvps.org/dmcritchie/excel/join.htm#trimall Directions to install and use a macro at http://www.mvps.org/dmcritchie/excel/getstarted.htm#havemacro I expect that you have spaces or CHAR(128) "Required Blank" characters in you data you can check is =LEN(A1) --- HTH, David...

sorting macro #3
I need to sort on 8 cells in a row and on 1500+rows. I can do it one at a time but I know there must be an easier way. Can ANYONE HELP? C3:J3 I need these cells sorted and then down to C1532:J1532 I did create a macro to sort after I selected them but still one at a time. Does it have to be a macro? I can edit a macro but don't really know how to program them. Yes, it has to be a macro. The following should do it. This macro loops through all the entries in Column C, and in each row it sorts the values in Columns C:J. HTH Otto Sub SortRows() Dim rColC As Range Dim i As...

how2: show contact name and phone fields in task list
It would be useful if I could display contact name and phone number fields in my task list. In Simple View I've used Field Chooser to insert these columns into the table .. but alas! the fields are blank. Can I do what I want to do and .. how? thanks Any folder view shows only the data in that folder, even though Outlook lets you think otherwise by allowing you to add fields from different types of items in the folder. You may be able to accomplish what you want, however, with a little custom VBA code. For an example, see http://www.outlookcode.com/codedetail.aspx?id=566 -- Su...

sum if and between dates
Hi all I am trying to sum information based on the following conditions Cell E3 = Sum if = *Account A* and between *>= 20/6/05 and <=24/6/05* The Answer would be 279 A B C D E 1 19/06/2005 Account A 125 20/06/2005 2 20/06/2005 Account A 150 24/06/2005 3 21/06/2005 Account B 156 Account A 4 22/06/2005 Account B 135 5 23/06/2005 Account C 142 6 24/06/2005 Account A 129 7 25/06/2005 Account C 200 8 26/06/2005 Account A 300 -- mathewheys ---------------------------------------------------...

Can we sort a form and also be able to enter new records.
Hi, It is possible to sort the data on a form and also be able to enter new and edit the existing records in it. Cheers! On Tue, 15 Jan 2008 15:41:16 -0800 (PST), Rex wrote: > Hi, > > It is possible to sort the data on a form and also be able to enter > new and edit the existing records in it. > > Cheers! I assume you mean "Is it". The form sort order has nothing to do with editing or adding new records, so the answer is yes. If you cannot edit or add new records, make sure the form's record source, if it is a query, is updateable. Some queries are not. O...

Sorting checking register
How do i sort my check register in Money 2004 Deluxe so that uncleared transactions appear below cleared transactions? In Quicken i could click on the column to provide that sort. In microsoft.public.money, Dean wrote: >How do i sort my check register in Money 2004 Deluxe so >that uncleared transactions appear below cleared >transactions? In Quicken i could click on the column to >provide that sort. You don't. Available choices are chosen by clicking View at the top of the register. ...

Is it possible to sequentially number the comments field
Anyone out there clever enough to tell me how to sequentially populate the comments field in cells... the problem I can see is that the cells are in a grid of A5-10 through to i5 to 10, I want them populating a5,a6,a7,a8,a9,a10,b5,b6 etc and when I get to i10 I want the sequence to carry over to the next sheet... Don't want much do I ;) TIA Nick It looks like rather than "sequentially" populating the Comment fields, you are simply putting the cell's address into the Comment field. If that observation is correct, then I do not know what you mean when you said "when ...

using addrress books to sort incoming mail
I use address books to sort incoming mail. An odd thing: depending on how the sender's name comes across, it doesn't get caught by the filter (amd moved to the "Family Mail" Folder I have set up. for example: my mom and dad's email (from momanddad@somedomain.com) comes as from that address. However, in my contacts, they are listed by their names: John and Mary Smith, with momanddad@somedomain.com as their email address and John and Mary Smith as the display name. What have I done wrong? TIA 1. The big ONE - failed to post your version of Outlook. Rules operate at ...

Form Field Auto-Resize
I have a form based on a table with Memo fields. Is it possible to have the form fields automatically resize if I cut and paste text from documents into the form? Thanks, (B^>)-]=[ On Tue, 20 Apr 2010 07:01:09 -0400, "WSR" <wsr203@hughes.net> wrote: No. CanGrow can be used with Reports. With forms you're on your own to do the resizing. Not a trivial task with proportional fonts. -Tom. Microsoft Access MVP >I have a form based on a table with Memo fields. Is it possible to have the >form fields automatically resize if I cut and paste...

Unmerge so I can sort
I coy/pasted data into Excell and when I try to sort it I get "This operation requires merged sells to be identically sized". I understadn the work around in KB but how do I find which sells are merged? I wouldn't bother looking. I'd just remove all the merged cells from the range to sort. Select that range format|cells|alignment tab uncheck the merge cells box But if you wanted to search, you can do it via process of elimination. Select a range, format|cells|alignment tab. If that merge cells box is checked, then the whole selection is merged. If it's grey, t...

How can I format the #of decimals, field types, etc. automaticall.
I am importing a delimited file, it can be a csv, tab delimted, doesn't matter, but I want it to come up in excel properly formatted to the # of decimal places each field is formatted with in the delimited file. I also want zip code to come in with a leading 0, not be interpreted as a number even though I have enclosed it in quotes. If you double click on a .csv file, excel will open it the way it wants. If you rename the file to .txt, you could see the import wizard and format each field as text--but that makes arithmetic a little more difficult. (I wouldn't do it this way.)...

sorting issue
Hi, When a range of columns are highlighted and a sort is performed on only one column empty cells above the sort display first. How can this be prevented. I know when there is data in any of the other column but not on the column being sorted this will happen. Any thoughts? Pat Are you sure the cells are really empty? They don't contain spaces or even formulas that evaluate to "". (Even formulas converted to values that returned "")? Pat wrote: > > Hi, > > When a range of columns are highlighted and a sort is performed on only one > column em...