Chat with a LIVE Microsoft Access Expert!
 
       
 

         

   

Go Back   Access World Forums > Microsoft Access Discussion > Tables

 
 
Chat with a LIVE Microsoft Access Expert!
Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 08-08-2007, 12:48 PM
rhett7660 rhett7660 is offline
Still Learning....
 
Join Date: Aug 2005
Location: Good ol USA
Posts: 356
rhett7660 is an unknown quantity at this point
Problem with setting up tables and relationship

Hello....

Here is what I am doing. It is an inventory database that also is an order tracking per se database.

When you are entering in the order, the top part is the vendor with an order number, date etc (will show table later).

The subform is the order details. This is the tricky part that I am having problems with.

In the subform I also need to have the unit that is placing the order for that particular item.

IE
product 1 pens black ball point unit=exams
product 2 pens red ball point unit=admin
product 3 paper legal color white unit=personnel


I can get it to work but the unit part is what is driving me nuts.

I am attaching a very stripped down version no queries etc....

Thanks
Attached Files
File Type: zip Ver 10.zip (22.2 KB, 14 views)
__________________
Just trying to figure this damn thing out called "Access"
Reply With Quote
Sponsored Links
  #2  
Old 08-08-2007, 01:57 PM
rhett7660 rhett7660 is offline
Still Learning....
 
Join Date: Aug 2005
Location: Good ol USA
Posts: 356
rhett7660 is an unknown quantity at this point
I think I figured it out.. I created a conjuction table with the following fields in it:

unitorderID
UnitID
ProductID

That seems to be working.....
__________________
Just trying to figure this damn thing out called "Access"
Reply With Quote
  #3  
Old 08-09-2007, 01:57 AM
neileg's Avatar
neileg neileg is offline
AWF VIP
 
Join Date: Dec 2002
Location: Newcastle, England
Posts: 5,971
neileg has a spectacular aura aboutneileg has a spectacular aura about
Mmm....

Beware of a problem you might have with this structure. Any changes you make to the Product data will be applied to old orders as well as new. It is customary to create an Order Details table that is populated with the product data at the time of creation of the order so that subsequent changes are only applied to new orders. Strictly speaking this violates some of the rules of normalisation but is widely accepted as a pragmatic solution.
__________________
You can't always get what you want, but if you try sometimes you may just get what you need - Rolling Stones

Cheers, Neil
Reply With Quote
  #4  
Old 08-09-2007, 02:15 AM
Rabbie's Avatar
Rabbie Rabbie is offline
AWF VIP
 
Join Date: Jul 2007
Location: In Exile in Wiltshire
Posts: 4,658
Rabbie has a spectacular aura aboutRabbie has a spectacular aura aboutRabbie has a spectacular aura about
Quote:
Originally Posted by neileg View Post
Strictly speaking this violates some of the rules of normalisation but is widely accepted as a pragmatic solution.
From a philosophical view point this is not the breach of normalisation that it seems because regardless of future changes this is recording what actually happened. You do want for example for an order detail to be updated with a later price change as this would cause confusion.

In one of my databases I use a Price list table to provide default descriptions and prices but store the actual information in an order detail table.
Reply With Quote
  #5  
Old 08-09-2007, 05:11 AM
neileg's Avatar
neileg neileg is offline
AWF VIP
 
Join Date: Dec 2002
Location: Newcastle, England
Posts: 5,971
neileg has a spectacular aura aboutneileg has a spectacular aura about
Quote:
Originally Posted by Rabbie View Post
From a philosophical view point this is not the breach of normalisation that it seems because regardless of future changes this is recording what actually happened. You do want for example for an order detail to be updated with a later price change as this would cause confusion.

In one of my databases I use a Price list table to provide default descriptions and prices but store the actual information in an order detail table.
I don't disagree in practice. However there are sad souls who insist that the 'correct' approach involves setting dates on your standing data and retrieving the data based on the transaction date. Waste of time and resources in my mind.
__________________
You can't always get what you want, but if you try sometimes you may just get what you need - Rolling Stones

Cheers, Neil
Reply With Quote
  #6  
Old 08-09-2007, 05:16 AM
Rabbie's Avatar
Rabbie Rabbie is offline
AWF VIP
 
Join Date: Jul 2007
Location: In Exile in Wiltshire
Posts: 4,658
Rabbie has a spectacular aura aboutRabbie has a spectacular aura aboutRabbie has a spectacular aura about
I think in the real world it is what works that is important. Knowing when to stick to the rules and when to ignore them is the real art of successful development.
Reply With Quote
  #7  
Old 08-09-2007, 07:23 AM
rhett7660 rhett7660 is offline
Still Learning....
 
Join Date: Aug 2005
Location: Good ol USA
Posts: 356
rhett7660 is an unknown quantity at this point
Hi all....

Thank you for the reply's.... I looked at both answers etc.... Can you tell me what other table(s) I would need to add.

I am still new at this, having a couple small databases under my belt, but this is by far been the most challenging.

Thanks
R~
__________________
Just trying to figure this damn thing out called "Access"
Reply With Quote
Sponsored Links
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Linked tables problem , any suggestion? nawaray Tables 5 08-01-2006 05:38 AM
Access xp pivot tables problem andrefrancis Forms 0 06-03-2006 02:03 AM
Date display problem with Firebird ODBC Tables Rob_rt Tables 2 09-27-2004 03:49 AM
Problem duplicating Access 97 database that has linked tables jimwei General 5 07-17-2003 05:32 AM


All times are GMT -8. The time now is 07:44 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
(c) copyright 2009 Access World