Results 1 to 6 of 6
  1. #1
    MrXYZ is offline Novice
    Windows 7 32bit Access 2003
    Join Date
    Aug 2012
    Posts
    5

    Return a value on to my form depending on the date/week number

    Hi,



    I have a form and I want it to show me stock levels for a particular week.

    My table lists each item number and then tells me the stock that we have for each week by number.

    On my form I want to return the quantity of the item that I am looking up, for each week. So I have a field on my form that I want to show week 38 and we have 20 in stock. Then in another field, to show me week 39 and we have 50 in stock.

    I have gotten this far, however, I want to update the table each week with new data, that does not include last week, so when I import the table, I want the form to update with the current weeks information, and the current weeks plus 1, so on and so forth.

    I hope this makes sense?

    Any help greatly appreciated

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    What is the table structure? You have a field for each week - 52 fields?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    MrXYZ is offline Novice
    Windows 7 32bit Access 2003
    Join Date
    Aug 2012
    Posts
    5
    Yes, sorry, this is exactly my structure. Each field is labelled by week number.

    Thanks

  4. #4
    Missinglinq's Avatar
    Missinglinq is offline VIP
    Windows 7 64bit Access 2007
    Join Date
    May 2012
    Location
    Richmond (Virginia, not North Yorkshire!)
    Posts
    3,018
    Quote Originally Posted by MrXYZ View Post

    Yes, sorry, this is exactly my structure. Each field is labelled by week number.
    Then you don't have a Relational Database, you have a Spreadsheet, which is what June7 was getting at!

    Check out CyberCow’s list of links (in Post #5) on the subject of Normalization:

    http://www.utteraccess.com/forum/Use...-t1986675.html

    Once your Database is properly Normalized, this and most other tasks will be much easier to do!

    Linq ;0)>
    The problem with making anything foolproof...is that fools are so darn ingenious!

    All posts/responses based on Access 2003/2007

  5. #5
    MrXYZ is offline Novice
    Windows 7 32bit Access 2003
    Join Date
    Aug 2012
    Posts
    5
    I have relationships within my database. All my tables are linked by the item number. They all feed into the master stock listing.


    Will check out your link though - thanks.

  6. #6
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    Linq is correct that your structure is not fully normalized.

    It is a balancing act between normalization and ease of data entry/output. I have a project that doesn't fully fit 'normalization' but it suits the way we want to output data.

    However, from the description of how you want form to work, would seem you need to normalize your data a bit more.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. Replies: 3
    Last Post: 04-01-2012, 01:40 PM
  2. Form to Filter Report by Week Number
    By jortizz in forum Forms
    Replies: 1
    Last Post: 05-18-2011, 09:30 AM
  3. Replies: 2
    Last Post: 08-18-2010, 02:09 PM
  4. Return blank field depending on quantity
    By anthonyjf in forum Access
    Replies: 1
    Last Post: 04-01-2009, 08:22 AM
  5. how to convert week number to date range
    By qwang1115 in forum Access
    Replies: 1
    Last Post: 02-13-2009, 11:35 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