Results 1 to 4 of 4
  1. #1
    grad2009 is offline Novice
    Windows XP Access 2007
    Join Date
    Feb 2010
    Posts
    27

    how to show all data in this querey


    hello guys,
    i have a query that shows the balance of each item, here is the query
    Code:
     
    SELECT Items.itemNo, Items.itemName, Items.type, Items.unit, Sum(Transactions.qtyIn) AS totalProcurements , Sum(Transactions.qtyOut) AS totalSales,totalProcurements- totalSales AS balance
    FROM Items INNER JOIN Transactions ON Items.itemNo=Transactions.ItemNo
    GROUP BY Items.itemNo, Items.itemName, Items.type, Items.unit;
    when i view data in this query it views only the items that have a value on the totalProcurements field, i want to view all the records even if the totalProcurements is zero.
    i hope that you understand what i want
    thanks with best regards,

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 Access 2007
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Use an OUTER or LEFT Join instead of an INNER Join.

  3. #3
    grad2009 is offline Novice
    Windows XP Access 2007
    Join Date
    Feb 2010
    Posts
    27
    thanks alot RuralGuy
    i did it and was ok
    regards,

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 Access 2007
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Glad we could help.

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

Similar Threads

  1. Chart doesn't show data
    By pbaxter in forum Forms
    Replies: 5
    Last Post: 01-20-2010, 11:09 AM
  2. Can't get new field to show in my data entry form
    By Suzie in forum Database Design
    Replies: 19
    Last Post: 12-21-2009, 03:48 PM
  3. Data won't show up in table field
    By texzen123 in forum Forms
    Replies: 3
    Last Post: 11-26-2009, 11:20 AM
  4. Replies: 0
    Last Post: 08-30-2006, 02:50 AM
  5. All Data wont show
    By Wrangler in forum Queries
    Replies: 1
    Last Post: 01-02-2006, 03:27 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