| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Query from Multiple Tables [newbie]
I created a simple inventory database but I guess it was not thought through.
Currently I have separate tables for computers, printers, monitors etc. These tables share a common field which is the room no. I need to make a query to display all equipment by room no. I made a few attempts but it did not display the query result correctly. How do I do this? Any help is appreciated. Thanks! |
|
#2
|
|||
|
|||
|
This is the SQL view:
SELECT CPU.RoomNo, CPU.Brand, CPU.Model, CPU.ServiceTag, Printer.Brand, Printer.Model, Printer.[Service Tag] FROM CPU INNER JOIN Printer ON CPU.RoomNo = Printer.RoomNo WHERE (((CPU.RoomNo)=[Room?])); In room 3114 for example, there are 4 CPU's and 3 printers. When this query runs, it shows 12 rows of results, each item repeating 4 times. |
![]() |
| Viewing: Tutorialized Forums > Databases > MS Access > Query from Multiple Tables [newbie] |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|