Results 1 to 2 of 2
  1. #1
    desp is offline Novice
    Windows XP Access 2003
    Join Date
    Oct 2011
    Posts
    1

    Unhappy Addup and Replacement values query

    Hi,

    I basically need a query where I have to add up numbers for groups of records, write the subtotals on the "leaders" of those groups, but write as well the original value for the non-leaders.

    Example:

    A and B are in "group1". C and D are in "group2". The table looks likes this:


    Element Number
    ___________________
    A 3


    B 2
    C 1
    D 5

    Suppose A is leader of group1 and D is leader of group2.

    This is what I want:

    Element (AggregatedNumber)
    _____________________________
    A 5
    B 2
    C 1
    D 6

    So far I have created a query to obtain this:

    Element Aggnumber
    A 5
    D 6


    So I'm trying to bring it back into the original table by creating relationships, but so far it hasn't worked. There are probably many other ways of solving this. Any ideas?

    your help is much appreciated!

    David

  2. #2
    orange's Avatar
    orange is online now Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726
    Based on the info you have provided, what tells us anything about Groups? Or Leader of a Group? I don't think you've given us all the info, or, you have a tables/structure issue.

    You may wish to read the Database materials at this site:
    http://forums.aspfree.com/attachment...achmentid=4712

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

Similar Threads

  1. Access 2010 Date Picker Replacement
    By pkstormy in forum Code Repository
    Replies: 3
    Last Post: 07-31-2012, 04:26 AM
  2. Sendkeys replacement
    By numberguy in forum Programming
    Replies: 6
    Last Post: 07-14-2011, 08:29 AM
  3. Query Table Values in Append Query
    By AKQTS in forum Queries
    Replies: 5
    Last Post: 11-12-2010, 03:58 PM
  4. Sendkeys replacement
    By numberguy in forum Forms
    Replies: 3
    Last Post: 10-29-2010, 07:20 AM
  5. Replacement in table with VB code
    By miziri in forum Access
    Replies: 2
    Last Post: 06-28-2010, 01:38 AM

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