Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 Updating Fields in other Tables

Author  Topic 

mango1
Starting Member

1 Post

Posted - 2006-06-29 : 09:14:59
Hello,

I just began learning Access and I've ran into a problem:

I have two tables, one named MachineInfo which contains information regarding a specific PC. The other table is named MonitorInfo, and it contains information for the monitors. Each PC and Monitor has an Asset Number, both of which are the Primary Keys for their respective table. I also use this Asset Number to link a monitor to a computer (on the MachineInfo table there is a Field named MonitorAssetNumber which is related to the Asset Number on the MonitorInfo table, also on the MonitorInfo table there is a Field named BelongsTo which is related to the Asset Number on the MachineInfo table).

There are then two forms, one named GeneralInfo and other named Monitor. The GeneralInfo form displays the information from the MachineInfo table and the Monitor form displays information from the MonitorInfo forms. I want to be able to change the MonitorAssetNumber on the GeneralInfo table, and when I do this, I need the BelongsTo value to change to the PC's Asset Number to which it is attached to. I'm really new at Access so any help would be greatly appreciated.

Thanks !

timmy
Master Smack Fu Yak Hacker

1242 Posts

Posted - 2006-06-29 : 18:17:27
Your problem is one of table design. There shouldn't be any need to provide double-links like this. It's just another thing that could go wrong.
My suggestion would be to have a single linking table (perhaps called BelongsTo) that lists the primary device (ie computer) with the things it owns (printers, monitors, etc). But if you're new to Access and db's in general this might be out of your depth.
With your current design, I would remove the MachineInfo.MonitorAssetNumber and leave the MonitorInfo table alone (this will allow for PC's that run dual monitors). You can use queries to determine what monitor belongs to what PC.

HTH,

Tim
Go to Top of Page
   

- Advertisement -