Results 1 to 5 of 5
  1. #1
    sk88 is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Aug 2011
    Posts
    183

    'Total rows' in query

    How do I make the 'total rows' in query permanently visible? Right now, every single time when I click on to my query, I will have to go to HOME---> RECORDS ---> TOTALS then the Total row will appear. And when I export that query, the TOTAL ROW is missing.



    Does anyone have any idea on how to make the total rows visible always?

  2. #2
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,596
    When I have needed to export the data from queries along with Counts / Totals / Averages etc, I have created reports and put all the Counts, Totals Averages at the bottom of the reports & then exported the Reports. That way all the totals go out along with the data.

  3. #3
    sk88 is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Aug 2011
    Posts
    183
    Quote Originally Posted by Robeen View Post
    When I have needed to export the data from queries along with Counts / Totals / Averages etc, I have created reports and put all the Counts, Totals Averages at the bottom of the reports & then exported the Reports. That way all the totals go out along with the data.

    Thanks Robeen.
    I am trying that now but how do I add the total row to the report and how do I export?


    I have this code already for exporting queries.
    Code:
                               
    Call DoCmd.TransferSpreadsheet(TransferType:=acExport, _
                                   TableName:="qryActivity", _
                                   FileName:="C:\Exports\qryExportMetrics.XLS")
    
    Call DoCmd.TransferSpreadsheet(TransferType:=acExport, _
                                   TableName:="qryCalled911", _
                                   FileName:="C:\Exports\qryExportMetrics.XLS")
    
    Call DoCmd.TransferSpreadsheet(TransferType:=acExport, _
                                   TableName:="qryCalled911Activity", _
                                   FileName:="C:\Exports\qryExportMetrics.XLS")

    Do I just change the TABLENAME for exporting report ?

  4. #4
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    if you're doing an export to a .xls file I'd suggest changing it to a .csv (comma separated value) file. In that you can export your rows line by line and create formulas in the fields you want to do your summation in, create sub total line etc.

  5. #5
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,596
    In your report, right-click a field and go to Total - Count Records.
    That will put a new row at the bottom with a count of the records in your report.

    You can also very easily add totals & subtotals etc.

    I usually set up a Macro with an 'ExportWithFormatting' Action [I'm using 2010] - and specify the Report as the object to be exported. It will ask for the type of file you want to export & the location.

    This method has proved very easy, flexible & reliable for me.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 08-28-2011, 06:06 AM
  2. Cumulative total in query
    By MikeWaring in forum Queries
    Replies: 2
    Last Post: 12-18-2010, 01:40 PM
  3. Help with Query Total
    By mohara in forum Queries
    Replies: 4
    Last Post: 08-20-2010, 02:35 PM
  4. Total all months in query or report
    By Brian62 in forum Queries
    Replies: 2
    Last Post: 10-23-2009, 08:41 AM
  5. Total a Query
    By Bridgid in forum Queries
    Replies: 0
    Last Post: 09-05-2009, 02:51 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums