Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2010
    Posts
    2

    Unanswered: Sum Fields in 2 different tables

    I have a 2 tables, one for parts received "tbl_received" and one for parts sent out "tbl_sent". On both tables i have the same product and i want to display on a form the difference between the 2 so that i know how many parts i have left:

    tbl_received
    part_received =10

    tbl_sent
    part_sent = 5

    I want the form to display on a box the difference between both so that it shows "Parts Available = 5"

    hope it makes sense

    PS. if possible i would prefer this to be done via an expression rather than writing a whole SQL query as i am quite new to Access

  2. #2
    Join Date
    May 2005
    Location
    Nevada, USA
    Posts
    2,888
    Provided Answers: 6
    If you're trying to avoid SQL, you could use 2 DSum() functions, subtracting sent from received.

    General: DLookup Usage Samples
    Paul

  3. #3
    Join Date
    Jan 2010
    Posts
    2

    to pbaldy

    Thank pbaldy

    As i said i am very new to access... Could you actually sent the actual expression...

  4. #4
    Join Date
    May 2005
    Location
    Nevada, USA
    Posts
    2,888
    Provided Answers: 6
    =DSum(...) - DSum(...)

    replacing ... with the appropriate syntax from the link.
    Last edited by pbaldy; 01-20-10 at 19:06.
    Paul

Posting Permissions

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