Results 1 to 6 of 6
  1. #1
    SHimmer45 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2012
    Posts
    2

    Order Database Design - does this look reasonable

    Hi all,


    attempting to design a simple order database and having some issues with reporting in Access 2010 before i start pulling the underlying structure about i needed a second opinion on the design as it been a long time since i actually designed a structure for a database.

    Click image for larger version. 

Name:	relationship.jpg 
Views:	40 
Size:	40.0 KB 
ID:	7187

    Does this look reasonable?

    The problem with the reporting is certain items appear grouped together which means i cant change how the report looks easily. (for example building the report with DEPT - ORDER - ITEM doesnt look correct as the order total appears before the item detail with the break down of the items within the order.

    might it be that i have got an unseen "many to many" relationship?

    regards

  2. #2
    pbaldy's Avatar
    pbaldy is online now Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    I wouldn't store the order total (or subtotal, whatever that is). I would calculate it from the line items. Presumably that's why you're seeing it before them. I've made that mistake, and I ended up regretting it. Users have a magical ability to find ways around whatever methods you might employ to keep the calculated value in balance with the line items.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    Join Date
    Apr 2012
    Location
    Los Angeles
    Posts
    75
    You need to group your report by Order_Num with an Order_Num header and footer and then add an unbound textbox to the footer with control source = "=Sum([Item_Qt]*[Item_Cost])". Your items table fields would go in the detail section of the report.

  4. #4
    SHimmer45 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2012
    Posts
    2
    ok thanks for the help, going to set about getting head around reporting again...

  5. #5
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726

  6. #6
    ssanfu is offline Master of Nothing
    Windows 2K Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    I would not use a text field to link tables. I would use "Dept_ID" and "Supplier_ID" to be the FK in the "Order" table.

    See http://www.accessmvp.com/Strive4Peac...Chapter_03.pdf , scroll down to "Data Type for Key Fields"

    My $0.02 worth

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

Similar Threads

  1. Vehicle work order database design
    By bacanter01 in forum Database Design
    Replies: 4
    Last Post: 03-22-2012, 07:58 PM
  2. Help - order chasing database
    By gskinstad in forum Import/Export Data
    Replies: 2
    Last Post: 02-14-2012, 10:41 AM
  3. Replies: 1
    Last Post: 04-13-2011, 11:14 AM
  4. Design tables in order to keep history
    By snoopy2003 in forum Database Design
    Replies: 2
    Last Post: 02-22-2011, 02:43 PM
  5. Service Order Database - Novice Looking for help.
    By Patriot7470 in forum Database Design
    Replies: 3
    Last Post: 02-16-2011, 08:50 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