+ Reply to Thread
Results 1 to 7 of 7

Thread: Please point me in the right direction

  1. #1
    Barn Newbie jchrisf is an unknown quantity at this point jchrisf's Avatar
    Join Date
    Jun 2008
    Posts
    21
    Rep Power
    4

    Please point me in the right direction

    I have a very simple Inventory database that is carrying a lot of inventory items. Basically there is a Product table that has Item Number, Description, etc and an Inventory table that has Item Number, Qty, Location, Bin, Lot #.

    What I want to do is create a form where I can have a History Table appended too (I guess) with information on Item #, Qty, Location, Bin, Lot#, Date and Description of the transaction.

    I have no idea what to do to append to this table from a form... if someone could give me an idea of what to do. Thanks

  2. #2
    Wolfmaster Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy's Avatar
    Join Date
    Mar 2008
    Location
    Peoria, IL
    Posts
    2,386
    Blog Entries
    5
    Real Name
    Wolff
    Rep Power
    15

    It look like you are trying to create a Transaction table here.

    First, unless a specific product item can only be stored in one location/bin/lot# combination, you will need to add a Primary Key on the Inventory table, otherwise, you will not be able to relate a specific transaction to the specific location from which the inventory item is pulled. Let's call this InventoryID

    With that in place, you can create a Transaction Table (or History Table). I'm going to assume that you only update this table when the inventory item is pulled. You can make it more complicated if you need by keeping the 'state' of the transaction, such as Entered, Approved, Picking, Pulled, Shipped, Backordered, Canceld, etc. You get the idea.

    The format of the Transaction Table then could be something like:
    Code:
    TrasnactionID -- Primary Key
    Inventory ID -- Location from which the item is pulled
    Qty -- Number of items pulled
    Date -- Date the items are pulled
    
    Then, when an inventory item is pulled, that data is saved in the database. Since you have Qty in the Inventory table as well, do forget to update that field.

    When you need to report on the History of a particular item, these three tables would be JOINed to produce the history information.

    You may want to create a Transaction record for when inventory is replenished as well.
    Wolffy
    .-- ----- ..-. ..-. -.--
    Opinions expressed are my own and do not necessity reflect those of any sane person. Any code provided is intended to be an example and is provided AS IS. Void where prohibited by law. Not valid in California. Your mileage may vary.

  3. #3
    Barn Newbie jchrisf is an unknown quantity at this point jchrisf's Avatar
    Join Date
    Jun 2008
    Posts
    21
    Rep Power
    4

    Thanks Wolffy! Another question. In my form how can I create a place next to the Qty to either add or subtract from the qty on hand at the time. Instead of figuring it out and changing the number I'd like to put a plus or minus number that the qty is changing and let that calculate the change and update the new number.

  4. #4
    Wolfmaster Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy's Avatar
    Join Date
    Mar 2008
    Location
    Peoria, IL
    Posts
    2,386
    Blog Entries
    5
    Real Name
    Wolff
    Rep Power
    15

    I'm not an Access developer, more of a data designer; so I can speak to Access directly. However, I don't think I would do it the way you are thinking. Rather, I see an Inventory Pull form that contains a Quantity field. The picker would enter the number of items pulled and when an Update button is click, the application would create the Transaction record and then update the Qty field in the Inventory table; subtracting the value of the Quantity field entered by the Picker. All this would be in the code executed by the Update button click event.

    Of course, you have to put some checks in there -- such as not allowing the number of item picked to exceed the quantity on hand, etc.
    Wolffy
    .-- ----- ..-. ..-. -.--
    Opinions expressed are my own and do not necessity reflect those of any sane person. Any code provided is intended to be an example and is provided AS IS. Void where prohibited by law. Not valid in California. Your mileage may vary.

  5. #5
    Barn Newbie jchrisf is an unknown quantity at this point jchrisf's Avatar
    Join Date
    Jun 2008
    Posts
    21
    Rep Power
    4

    Ok... so then this entails some coding in VBA? A little out of my ball park unless you know of some I can reuse for this.

  6. #6
    Wolfmaster Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy is a splendid one to behold Wolffy's Avatar
    Join Date
    Mar 2008
    Location
    Peoria, IL
    Posts
    2,386
    Blog Entries
    5
    Real Name
    Wolff
    Rep Power
    15

    Coding is a part of life in the DB world. We have some good Access folks here. Perhaps once the weekend is over they can comment here.

    This isn't a very hard bit of code, so would probably be a good way to get into the fray. And this site is a good resource if you get stuck.
    Wolffy
    .-- ----- ..-. ..-. -.--
    Opinions expressed are my own and do not necessity reflect those of any sane person. Any code provided is intended to be an example and is provided AS IS. Void where prohibited by law. Not valid in California. Your mileage may vary.

  7. #7
    Barn Newbie jchrisf is an unknown quantity at this point jchrisf's Avatar
    Join Date
    Jun 2008
    Posts
    21
    Rep Power
    4

    Great! I look forward to learning this from the folks here!

+ Reply to Thread

Similar Threads

  1. Charts (direction/advice)
    By Rebelle in forum ASP Development
    Replies: 3
    Last Post: January 30th, 2009, 09:57 AM
  2. Share Point
    By todd2006 in forum .NET Development
    Replies: 6
    Last Post: July 10th, 2008, 09:56 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

SEO by vBSEO