Results 1 to 7 of 7
  1. #1
    1943 is offline Novice
    Windows XP Access 2003
    Join Date
    Feb 2011
    Posts
    7

    Inventory Query Problem


    I am having a problem with getting the qty rec, qty sold and instock to work. It is not adding to the existing stock on hand.

    Can someone PLEASE help,

    Thanks,
    DWH

  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
    Is this your entire database?


    QtyOnHand = QtyRecd- QtySold

    You may want to look here for some inventory data models
    http://www.databaseanswers.org/data_models/index.htm

    and
    http://www.databaseanswers.org/data_...ders/index.htm

    http://www.tech-archive.net/Archive/.../msg00082.html

  3. #3
    1943 is offline Novice
    Windows XP Access 2003
    Join Date
    Feb 2011
    Posts
    7
    Hi,
    Thanks for the reply.
    No this is not the entire db. I am trying to modify an existing db.
    I created this db to try and figure out how to use Dsum or Sum.
    I read the article by Allen Browne on Inventory Control.
    His suggestion was to use Dsum. How do I do this?

    Thanks,
    DWH

  4. #4
    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
    Details of Allen's Inventory

    http://allenbrowne.com/appinventory.html

  5. #5
    1943 is offline Novice
    Windows XP Access 2003
    Join Date
    Feb 2011
    Posts
    7
    He says, Just use DSum() on the table of acquisitions to get the number acquired for any product . This for a simple db.
    How do I do this. I don't know how to apply this function DSum.
    I have tried and tried with no success.
    Do you know how?

    Thanks,

    DWH

  6. #6
    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
    Here is an example of DSum, and you will see code that shows what DSum is really doing.

    http://www.techonthenet.com/access/f...omain/dsum.php

    In Allen's example
    http://allenbrowne.com/AppInventory.html

    he is using SQL to calculate " QuantityAcq"
    and he uses this to calculate " lngQtyAcq "
    He also does this with " lngQtyLast" and " lngQtyUsed" and then does

    Code:
    'Assign the return value
            OnHand = lngQtyLast + lngQtyAcq - lngQtyUsed

  7. #7
    1943 is offline Novice
    Windows XP Access 2003
    Join Date
    Feb 2011
    Posts
    7
    Hi,
    Thanks for the reply.
    Think I am going to reevaluate what I am trying to do.

    Thank you very much!

    DWH

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

Similar Threads

  1. Inventory Tracking
    By PUDrummer in forum Access
    Replies: 3
    Last Post: 10-10-2012, 05:42 AM
  2. Inventory issue
    By Anasua in forum Programming
    Replies: 5
    Last Post: 01-28-2011, 08:56 AM
  3. Inventory usage
    By txrules in forum Database Design
    Replies: 1
    Last Post: 12-30-2010, 12:35 PM
  4. Running an inventory query
    By EDEd in forum Queries
    Replies: 1
    Last Post: 10-08-2010, 11:54 AM
  5. Inventory Database
    By kram941 in forum Access
    Replies: 2
    Last Post: 11-09-2009, 04:28 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