+ Reply to Thread
Results 1 to 4 of 4

Subtotals For 1 column

  1. #1
    Forum Contributor
    Join Date
    10-27-2013
    Location
    Columbus Ohio
    MS-Off Ver
    Excel 2010
    Posts
    137

    Subtotals For 1 column

    Hello memebers. I have an access DB i am trying to get subtotals for. The table being used is called tbl100 and it houses our inventory. There are 4 columns: Bin, Qty,Item, Zone All fields are text except Qty. There are 8 zones Zone 101, Zone 102.....up to Zone 108. I am trying to sum the totals for each zone in one query. I had originally done 8 different queries with a different WHERE clause in each. I have now tried to union the table upon itself but that places all the totals in the same column. Is there an easier way to sum up the Total Qty for each zone in one Query? Ideally the column names should be returned as Zone 1, Zone 2... Zone 8 with the totals underneath.

  2. #2
    Forum Contributor
    Join Date
    10-27-2013
    Location
    Columbus Ohio
    MS-Off Ver
    Excel 2010
    Posts
    137

    Re: Subtotals For 1 column

    For the union query I am using the following code:
    Please Login or Register  to view this content.

  3. #3
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,885

    Re: Subtotals For 1 column

    Why not just make one aggregate query that groups on the zone. Look at this link on aggregate queries. Post back if you need additional help

    http://www.techonthenet.com/access/f...umeric/sum.php
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  4. #4
    Registered User
    Join Date
    09-17-2014
    Location
    Plymouth, MN, USA
    MS-Off Ver
    2010
    Posts
    1

    Re: Subtotals For 1 column

    SELECT tbl100.Zone, Sum(tbl100.Qty) AS SumOfQty
    FROM tbl100
    GROUP BY tbl100.Zone;

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Quickly Get Subtotals From A Column
    By abrogard in forum Excel General
    Replies: 2
    Last Post: 08-28-2013, 12:05 AM
  2. [SOLVED] Move subtotals into new column
    By Ozzanif in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 10-22-2012, 03:46 PM
  3. How to create subtotals in more than one column
    By sentinela in forum Excel General
    Replies: 1
    Last Post: 07-02-2009, 09:15 AM
  4. copy subtotals to new column
    By shekar goud in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-04-2009, 08:59 AM
  5. copy subtotals to new column
    By shekar goud in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 06-04-2009, 06:39 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1